Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#202, #224 simplify configation - alternative to #6 #10

Closed
wants to merge 2 commits into from

Conversation

dingsda87
Copy link
Contributor

this is an alternative to #6

as mentioned in http://tracker.adventure-php-framework.org/view.php?id=202#c455 it would be better if there is no need to apply another parameter when using the configuration.

I followed suggestion b) and use a fix delimiter in the baseConfiguration.

allow more comfortable ini configuration like
[configsection]
value1=foo
value2=bar
value3=dummy
[configsection.subsection]
value1=foo
value2=foo
value3=foo
value4=foo
[configsection.subsection.subsubsection1]
value1=foo
value2=bar
value3=blub
value4=dummy
[configsection.subsection.subsubsection2]
value1=foo
value2=bar
value3=blub
value4=dummy
change BaseConfiguration to use '.' as section delimiter by default without the ability to change it
allow requesting and setting values and section of lower levels by using the subsection delimiter
examples
$section -> getSection($name='subSection.subSubSection');
$section -> setSection($name='subSection/subSubSection', $newSubsection);

private function explodePath($name){

$pathArray = explode('.',$name);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why dont you use $this->sectionDelimiter here instead of '.'?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just a mistake. will be corrected

@ChristianAchatz
Copy link
Member

Used your suggestion to implement a solution as discussed in http://tracker.adventure-php-framework.org/view.php?id=224. Thus closing this request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants