forked from loafle/openapi-generator-original
Merge pull request #2266 from wing328/php_better_local_var
[Ruby][Python][PHP] better local variable naming for ruby, python and php
This commit is contained in:
@@ -52,7 +52,7 @@ public class PhpClientCodegen extends DefaultCodegen implements CodegenConfig {
|
||||
setReservedWordsLowerCase(
|
||||
Arrays.asList(
|
||||
// local variables used in api methods (endpoints)
|
||||
"resourcePath", "method", "httpBody", "queryParams", "headerParams",
|
||||
"resourcePath", "httpBody", "queryParams", "headerParams",
|
||||
"formParams", "_header_accept", "_tempBody",
|
||||
|
||||
// PHP reserved words
|
||||
|
||||
@@ -59,8 +59,8 @@ public class PythonClientCodegen extends DefaultCodegen implements CodegenConfig
|
||||
setReservedWordsLowerCase(
|
||||
Arrays.asList(
|
||||
// local variable name used in API methods (endpoints)
|
||||
"all_params", "resource_path", "method", "path_params", "query_params",
|
||||
"header_params", "form_params", "files", "body_params", "auth_settings",
|
||||
"all_params", "resource_path", "path_params", "query_params",
|
||||
"header_params", "form_params", "local_var_files", "body_params", "auth_settings",
|
||||
// python reserved words
|
||||
"and", "del", "from", "not", "while", "as", "elif", "global", "or", "with",
|
||||
"assert", "else", "if", "pass", "yield", "break", "except", "import",
|
||||
|
||||
@@ -61,7 +61,7 @@ public class RubyClientCodegen extends DefaultCodegen implements CodegenConfig {
|
||||
setReservedWordsLowerCase(
|
||||
Arrays.asList(
|
||||
// local variable names used in API methods (endpoints)
|
||||
"path", "query_params", "header_params", "_header_accept", "_header_accept_result",
|
||||
"local_var_path", "query_params", "header_params", "_header_accept", "_header_accept_result",
|
||||
"_header_content_type", "form_params", "post_body", "auth_names",
|
||||
// ruby reserved keywords
|
||||
"__FILE__", "and", "def", "end", "in", "or", "self", "unless", "__LINE__",
|
||||
|
||||
Reference in New Issue
Block a user