Go to the source code of this file.
Functions | |
| foreach($schema['objects'] as $obj_name=> $params) | reorderParams (Array $input) |
| makeConstructorParams (Array &$input) | |
| makeProperties (Array $input) | |
| makeConstructorContent (Array $input) | |
| makeSetFunctions (array $input) | |
| makeTypeArrayBody (Array $input) | |
| makeToArrayBody (Array $input) | |
Variables | |
| const | TARGET_PATH __DIR__ . '/../src/DataType' |
| $scriptName = 'scripts/'. basename(__FILE__) | |
| $shouldWriteToDisc = (isset($GLOBALS['argv'][1]) && $GLOBALS['argv'][1] === '--no-file-generation') ? false : true | |
| $file_header | |
| $schema = getSchema() | |
| $limit = 100 | |
Generates interface Web3Methods.
Generating from resources/ethjs-schema.json -> objects.
Definition in file generate-complex-datatypes.php.
| makeConstructorContent | ( | Array | $input | ) |
Create constructor content.
| array | $input | - ['params' => ['name'=> Type, 'name'=> Type ...], 'required' => ['name', 'name' ...] ] |
Definition at line 247 of file generate-complex-datatypes.php.
| makeConstructorParams | ( | Array & | $input | ) |
Create constructor parameters.
| array | $input | - ['params' => ['name'=> Type, 'name'=> Type ...], 'required' => ['name', 'name' ...] ] |
Definition at line 181 of file generate-complex-datatypes.php.
| makeProperties | ( | Array | $input | ) |
Create properties.
| array | $input | - ['params' => ['name'=> Type, 'name'=> Type ...], 'required' => ['name', 'name' ...] ] |
Definition at line 225 of file generate-complex-datatypes.php.
| makeSetFunctions | ( | array | $input | ) |
Create set_<PROPERTY> functions content.
| array | $input | ['params' => ['name'=> Type, 'name'=> Type ...], 'required' => ['name', 'name' ...] ] |
| Exception |
Definition at line 268 of file generate-complex-datatypes.php.
| makeToArrayBody | ( | Array | $input | ) |
Create return array.
| array | $input | - ['params' => ['name'=> Type, 'name'=> Type ...], 'required' => ['name', 'name' ...] ] |
Definition at line 332 of file generate-complex-datatypes.php.
| makeTypeArrayBody | ( | Array | $input | ) |
Create Constructor from array.
| array | $input | ['params' => ['name'=> Type, 'name'=> Type ...], 'required' => ['name', 'name' ...] ] |
Definition at line 309 of file generate-complex-datatypes.php.
| foreach ( $schema[ 'objects'] as $obj_name=> $params) reorderParams | ( | Array | $input | ) |
Reorder parameters.
Prioritizing required params over unrequired ones.
| array | $input | Parameter array. |
Definition at line 151 of file generate-complex-datatypes.php.
| $file_header |
Definition at line 42 of file generate-complex-datatypes.php.
| $limit = 100 |
Definition at line 58 of file generate-complex-datatypes.php.
| $schema = getSchema() |
Definition at line 56 of file generate-complex-datatypes.php.
Referenced by EthDataType\getAllTypeClasses().
| $scriptName = 'scripts/'. basename(__FILE__) |
Definition at line 32 of file generate-complex-datatypes.php.
| $shouldWriteToDisc = (isset($GLOBALS['argv'][1]) && $GLOBALS['argv'][1] === '--no-file-generation') ? false : true |
Definition at line 35 of file generate-complex-datatypes.php.
| const TARGET_PATH __DIR__ . '/../src/DataType' |
Definition at line 27 of file generate-complex-datatypes.php.