Comments (6)
I also ran into a problem when using forward slashes per the README.md. I realize that Windows paths use backslashes and Mac/Linux paths uses forward slashes. I think what is going on here is that namespaces are the problem, not filesystem paths.
When I first was reading, I was a bit confused as to why forward slashes would be used for defining PHP namespaces (but tried using them anyway). Using forward slashes would cause me to receive an error: "Unable to determine location to save PHP class ..." Changing to backslashes worked for me (I'm using Linux). Perhaps someone with Windows can confirm that namespaces with backslash work well for them too?
I think it is worth noting that the explanations of config.yml use backslashes, yet the sample config.yml uses forward slashes. Screenshot below...
from xsd2php.
/ are for mac Unix and Linux based systems
\ are for windows
Not sure if this should be documented
from xsd2php.
Was this the issue?
from xsd2php.
Quoting depends on yaml specifications.. and I'm not really deep into it
from xsd2php.
Not sure if this should be documented
Think this would be useful yes... I really had to puzzle a bit until I got it working and started doubting my configuration. A short comment can already help starting users:
destinations_php:
#On Windows
TestNs/MyApp: soap/src
#On Mac, Unix, Linux, etc
TestNs\MyApp: soap/src
Quoting depends on yaml specifications.. and I'm not really deep into it
Ok, well, my personal approach would be to leave as little to interpretation as possible, so either use it consistently (both for the key AND the value):
destinations_php:
#On Windows
'TestNs/MyApp': 'soap/src'
#On Mac, Unix, Linux, etc
'TestNs\MyApp': 'soap/src'
or not at all:
destinations_php:
#On Windows
TestNs/MyApp: soap/src
#On Mac, Unix, Linux, etc
TestNs\MyApp: soap/src
just my 2 cents, not big issues
from xsd2php.
fixed with c93698f
from xsd2php.
Related Issues (20)
- types used in php classes are different than types used in the yaml configs HOT 3
- Namespace for array element - xml_list HOT 3
- Not working with Symfony HOT 1
- Deserializing boolean values HOT 6
- Handlers dosn't work. Class `GoetasWebservices\Xsd\XsdToPhp\XMLSchema\Date does not exist HOT 3
- xml attribute cause Uncaught ReflectionException: Class \ does not exist because it seaches empty class HOT 2
- Unable to generate PHP classes from XML file
- Validation metadata setting max count = 2 to elements with no maxOccurs.
- No namespace(s). What to do? HOT 1
- Problems with JMS-Metadata-Generator HOT 4
- Improper PHP code form choice element HOT 2
- Unable to generate PHP classes from XSD file HOT 3
- Declaration of Xsd2PhpExtension::getAlias() must be compatible with Symfony\Component\DependencyInjection\Extension\Extension::getAlias() HOT 4
- Better Handling of xsd:choice
- [Feature Request] Add option to add PHP type declarations
- Handling of xsd:squence with maxOccurs="unbounded"
- Composer requirements version HOT 3
- still uses psr/log:^1.0 - Please add support for psr/log:^3.0 and ^2.0 HOT 3
- CDATA sections not being disabled in XML despite setting xml_cdata to false in goetas-webservices/xsd2php HOT 2
- Can you help me create config.yml
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xsd2php.