2017 © Pedro Peláez
 

project dodo-ini-manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

image

dimitrilahaye/dodo-ini-manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  • Monday, May 9, 2016
  • by dimitrilahaye
  • Repository
  • 1 Watchers
  • 0 Stars
  • 0 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 11 Versions
  • 0 % Grown

The README.md

 Dodo Ini Manager Library

Awakens the dodo which is sleeping in you!, (*1)

And at least, manage your files.ini ! Create them, update their sections, etc., (*2)

Table of Contents

FileIni

General class for DodoIniManager. Provides all the methods to :, (*5)

  • Create and modify file.ini
  • Create and modify sections
  • Create and modify section's keys and their values
  • Full name: \DodoPhpLab\DodoIniManager\Classes\FileIni

__construct

Method constructor. When a new FileIni object is instantiated, if file doesn't exists, we create it., (*6)

FileIni::__construct( string $path ): void

Parameters:, (*7)

Parameter Type Description
$path string File's path for this FileIni object.

See Also:, (*8)

  • \DodoPhpLab\DodoIniManager\Classes\FileIni::createFile() - For the creation of the file.ini.

getPath

Get the path for this FileIni object., (*9)

FileIni::getPath(  ): string

Return Value:, (*10)

Returns the file's path for this FileIni object., (*11)


rename

Change the file's name., (*12)

FileIni::rename( string $name ): void

Parameters:, (*13)

Parameter Type Description
$name string New name for this file.

copy

Create a copy of the file with another name, at the same location in file system., (*14)

FileIni::copy( string $name ): void

Parameters:, (*15)

Parameter Type Description
$name string Name for the copied file.

move

Change location for this file. The original file is deleted., (*16)

FileIni::move( string $path ): void

Parameters:, (*17)

Parameter Type Description
$path string The new path for this file.

arrayTo

Update entire file with an array, (*18)

FileIni::arrayTo( mixed[] $array ): void

Parameters:, (*19)

Parameter Type Description
$array arraymixed,mixed The array content to update the file.

toArray

Get the parsed content of this file., (*20)

FileIni::toArray(  ): mixed[]

Return Value:, (*21)

The parsed content of this file obtained with parse_ini_file() method., (*22)


jsonTo

Update entire file with a json array, (*23)

FileIni::jsonTo( string $json ): void

Parameters:, (*24)

Parameter Type Description
$json string The json array content to update the file.

toJson

Get the parsed content of this file in json array format., (*25)

FileIni::toJson(  ): \DodoPhpLab\DodoIniManager\Classes\json

Return Value:, (*26)

The parsed content of this file obtained in json array format., (*27)


hasSection

Check if this file.ini has a section specified by the name passed in argument., (*28)

FileIni::hasSection( string $section ): boolean

Parameters:, (*29)

Parameter Type Description
$section string The name of the searched section.

Return Value:, (*30)

True if the section exists in file.ini, false if not., (*31)


get

Get a section contained into this file., (*32)

FileIni::get( string $section ): mixed[]

Parameters:, (*33)

Parameter Type Description
$section string The target section's key.

Return Value:, (*34)

Returns the section from parsed file., (*35)


set

Add a new section to this file. You are able to add an array of sub-keys for this new section., (*36)

FileIni::set( string $section, mixed[] $array = null ): void

Parameters:, (*37)

Parameter Type Description
$section string The section's key to add.
$array arraymixed,mixed An array of key => value in case we want to write element to this new section

rewrite

Modify the key of a section., (*38)

FileIni::rewrite( string $section, string $newSection ): void

Parameters:, (*39)

Parameter Type Description
$section string The section's key to modify.
$newSection string The new section's key.

rm

Remove the section with the key passed in argument., (*40)

FileIni::rm( string $section ): void

Parameters:, (*41)

Parameter Type Description
$section string The section's key of the section to remove.

prepend

Move an entire section at the top of this file.ini, (*42)

FileIni::prepend( string $section ): void

Parameters:, (*43)

Parameter Type Description
$section string The section's key of the section to move.

append

Move an entire section at the bottom of this file.ini, (*44)

FileIni::append( string $section ): void

Parameters:, (*45)

Parameter Type Description
$section string The section's key of the section to move.

before

Move an entire section before another one., (*46)

FileIni::before( string $section, string $before ): void

Parameters:, (*47)

Parameter Type Description
$section string The section's key of the section to move.
$before string The section's key of the section before wich we want to move our section.

after

Move an entire section after another one., (*48)

FileIni::after( string $section, string $after ): void

Parameters:, (*49)

Parameter Type Description
$section string The section's key of the section to move.
$after string The section's key of the section after wich we want to move our section.

hasNext

Check if this section has another section after it., (*50)

FileIni::hasNext( string $section ): boolean

Parameters:, (*51)

Parameter Type Description
$section string The section's key we want to evaluate.

Return Value:, (*52)

True if this section has another one after it, false if not., (*53)


hasPrevious

Check if this section has another section before it., (*54)

FileIni::hasPrevious( string $section ): boolean

Parameters:, (*55)

Parameter Type Description
$section string The section's key we want to evaluate.

Return Value:, (*56)

True if this section has another one before it, false if not., (*57)


getNext

Get the next section after the section'key passed in argument., (*58)

FileIni::getNext( string $section ): mixed[]

Parameters:, (*59)

Parameter Type Description
$section string The section's key that we want to return the following.

Return Value:, (*60)

Returns the following section from parsed file., (*61)


getPrevious

Get the next section before the section'key passed in argument., (*62)

FileIni::getPrevious( string $section ): mixed[]

Parameters:, (*63)

Parameter Type Description
$section string The section's key that we want to return the previous one.

Return Value:, (*64)

Returns the previous section from parsed file., (*65)


hasKey

Check if the target section has a key value specified by the name passed in argument., (*66)

FileIni::hasKey( string $section, string $element ): boolean

Parameters:, (*67)

Parameter Type Description
$section string The name of the section where to search the key value.
$element string The name of the searched key value.

Return Value:, (*68)

True if key value exists in section, false if not., (*69)


getKey

Get an element contained into a section of this file., (*70)

FileIni::getKey( string $section, string $element ): string

Parameters:, (*71)

Parameter Type Description
$section string The section's key of the target element.
$element string The target element.

Return Value:, (*72)

Returns the value of the target element, (*73)


setKey

Add a new element into a section of this file. You are able to add an array of sub-keys in second argument in order to add many elements into the target section or just a string in order to add a simple sub-key., (*74)

FileIni::setKey( string $section, mixed[] $element ): void

Parameters:, (*75)

Parameter Type Description
$section string The section's key of the target element.
$element arraymixed,mixed The target element.

writeInKey

Add a value into the element of a section into this file., (*76)

FileIni::writeInKey( string $section, string $element, string $content ): void

Parameters:, (*77)

Parameter Type Description
$section string The section's key of the target element.
$element string The target element.
$content string The value to write in the element.

rewriteKey

Modify the element's key of a section into this file., (*78)

FileIni::rewriteKey( string $section, string $element, string $newElement ): void

Parameters:, (*79)

Parameter Type Description
$section string The section's key of the target element.
$element string The target element.
$newElement string The new name for the target element.

rewriteInKey

Overwrite a value into the element of a section into this file., (*80)

FileIni::rewriteInKey( string $section, string $element, string $content ): void

Parameters:, (*81)

Parameter Type Description
$section string The section's key of the target element.
$element string The target element.
$content string The value to write in the element.

rmInKey

Remove the value into a target element in a section of this file., (*82)

FileIni::rmInKey( string $section, string $element ): void

Parameters:, (*83)

Parameter Type Description
$section string The section's key of the target element.
$element string The target element.

rmKey

Remove the entire element's key/value into a section of this file., (*84)

FileIni::rmKey( string $section, string $element ): void

Parameters:, (*85)

Parameter Type Description
$section string The section's key of the target element.
$element string The target element to remove.

keyHasNext

Check if this section's element has another element after it., (*86)

FileIni::keyHasNext( string $section, string $element ): boolean

Parameters:, (*87)

Parameter Type Description
$section string The section's key of the target element.
$element string The target element to evaluate.

Return Value:, (*88)

True if this element has another one after it, false if not., (*89)


keyHasPrevious

Check if this section's element has another element before it., (*90)

FileIni::keyHasPrevious( string $section, string $element ): boolean

Parameters:, (*91)

Parameter Type Description
$section string The section's key of the target element.
$element string The target element to evaluate.

Return Value:, (*92)

True if this element has another one before it, false if not., (*93)


getNextKey

Get the next element after the element'key passed in argument., (*94)

FileIni::getNextKey( string $section, string $element ): string

Parameters:, (*95)

Parameter Type Description
$section string The section's key of the target element.
$element string The section's element's key that we want to return the following.

Return Value:, (*96)

Returns the following element from parsed file., (*97)


getPreviousKey

Get the element before the element'key passed in argument., (*98)

FileIni::getPreviousKey( string $section, string $element ): string

Parameters:, (*99)

Parameter Type Description
$section string The section's key of the target element.
$element string The section's element's key that we want to return the previous one.

Return Value:, (*100)

Returns the previous element from parsed file., (*101)


moveKey

Move the element into another section. The original element is deleted., (*102)

FileIni::moveKey( string $section, string $element, string $newSection ): void

Parameters:, (*103)

Parameter Type Description
$section string The section's key of the target element.
$element string The element's key to move.
$newSection string The section's key where to move the element.

beforeKey

Move an entire element's key/value before another one., (*104)

FileIni::beforeKey( string $section, string $element, string $before ): void

Parameters:, (*105)

Parameter Type Description
$section string The section's key of the element to move.
$element string The element's key of the element to move.
$before string The element's key before wich we want to move our element.

afterKey

Move an entire element's key/value after another one., (*106)

FileIni::afterKey( string $section, string $element, string $after ): void

Parameters:, (*107)

Parameter Type Description
$section string The section's key of the element to move.
$element string The element's key of the element to move.
$after string The element's key after wich we want to move our element.

prependKey

Move an entire element at the top of its section., (*108)

FileIni::prependKey( string $section, string $element ): void

Parameters:, (*109)

Parameter Type Description
$section string The section's key of the section's element to move.
$element string The element's key to move.

appendKey

Move an entire element at the bottom of its section., (*110)

FileIni::appendKey( string $section, string $element ): void

Parameters:, (*111)

Parameter Type Description
$section string The section's key of the section's element to move.
$element string The element's key to move.

 Coming Soon

  • Manage exceptions (section, element not found..), (*112)

  • Add sample code in README.md, (*113)

  • Add new cool methods : suggestions are welcome and usefull ;), (*114)


This document was automatically generated from source code comments on 2016-04-27 using phpDocumentor and cvuorinen/phpdoc-markdown-public, (*115)

The Versions

09/05 2016

dev-master

9999999-dev https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

09/05 2016

0.1.8-beta

0.1.8.0-beta https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

01/05 2016

0.1.7.1-beta

0.1.7.1-beta https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

01/05 2016

0.1.7-beta

0.1.7.0-beta https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

30/04 2016

0.1.6-beta

0.1.6.0-beta https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

30/04 2016

0.1.5-beta

0.1.5.0-beta https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

29/04 2016

0.1.4-beta

0.1.4.0-beta https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

29/04 2016

0.1.3-beta

0.1.3.0-beta https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

29/04 2016

0.1.2-beta

0.1.2.0-beta https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

28/04 2016

0.1.1-alpha1

0.1.1.0-alpha1 https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

  • php >=5.4

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo

28/04 2016

0.1.0-alpha1

0.1.0.0-alpha1 https://github.com/dimitrilahaye/Dodo-Ini-Manager

Awakens the dodo which is sleeping in you! And at least, manage your files.ini ! Create them, update their sections, etc.

  Sources   Download

proprietary

The Requires

 

The Development Requires

by Dimitri Lahaye

file parser ini manager sections dodo