diff options
author | LianaHus <liana@ethdev.com> | 2015-09-01 00:44:29 +0800 |
---|---|---|
committer | LianaHus <liana@ethdev.com> | 2015-09-08 19:12:00 +0800 |
commit | 1b5e6fc9e76ad3cf30e6e7bfc0e868dbb5267ff4 (patch) | |
tree | 6ecb1323bec51a67a53d63bfd250f4ccfcee926c /libsolidity/ASTJsonConverter.cpp | |
parent | 6f4a39c183a905b8e07da59c17bfd25c2febbf7f (diff) | |
download | dexon-solidity-1b5e6fc9e76ad3cf30e6e7bfc0e868dbb5267ff4.tar dexon-solidity-1b5e6fc9e76ad3cf30e6e7bfc0e868dbb5267ff4.tar.gz dexon-solidity-1b5e6fc9e76ad3cf30e6e7bfc0e868dbb5267ff4.tar.bz2 dexon-solidity-1b5e6fc9e76ad3cf30e6e7bfc0e868dbb5267ff4.tar.lz dexon-solidity-1b5e6fc9e76ad3cf30e6e7bfc0e868dbb5267ff4.tar.xz dexon-solidity-1b5e6fc9e76ad3cf30e6e7bfc0e868dbb5267ff4.tar.zst dexon-solidity-1b5e6fc9e76ad3cf30e6e7bfc0e868dbb5267ff4.zip |
renamed getter functions
Diffstat (limited to 'libsolidity/ASTJsonConverter.cpp')
-rw-r--r-- | libsolidity/ASTJsonConverter.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/libsolidity/ASTJsonConverter.cpp b/libsolidity/ASTJsonConverter.cpp index 122b1c0d..82c48a73 100644 --- a/libsolidity/ASTJsonConverter.cpp +++ b/libsolidity/ASTJsonConverter.cpp @@ -90,19 +90,19 @@ Json::Value const& ASTJsonConverter::json() bool ASTJsonConverter::visit(ImportDirective const& _node) { - addJsonNode("Import", { make_pair("file", _node.getIdentifier())}); + addJsonNode("Import", { make_pair("file", _node.identifier())}); return true; } bool ASTJsonConverter::visit(ContractDefinition const& _node) { - addJsonNode("Contract", { make_pair("name", _node.getName()) }, true); + addJsonNode("Contract", { make_pair("name", _node.name()) }, true); return true; } bool ASTJsonConverter::visit(StructDefinition const& _node) { - addJsonNode("Struct", { make_pair("name", _node.getName()) }, true); + addJsonNode("Struct", { make_pair("name", _node.name()) }, true); return true; } @@ -115,7 +115,7 @@ bool ASTJsonConverter::visit(ParameterList const&) bool ASTJsonConverter::visit(FunctionDefinition const& _node) { addJsonNode("Function", - { make_pair("name", _node.getName()), + { make_pair("name", _node.name()), make_pair("public", boost::lexical_cast<std::string>(_node.isPublic())), make_pair("const", boost::lexical_cast<std::string>(_node.isDeclaredConst())) }, true); @@ -124,7 +124,7 @@ bool ASTJsonConverter::visit(FunctionDefinition const& _node) bool ASTJsonConverter::visit(VariableDeclaration const& _node) { - addJsonNode("VariableDeclaration", { make_pair("name", _node.getName()) }, true); + addJsonNode("VariableDeclaration", { make_pair("name", _node.name()) }, true); return true; } @@ -135,13 +135,13 @@ bool ASTJsonConverter::visit(TypeName const&) bool ASTJsonConverter::visit(ElementaryTypeName const& _node) { - addJsonNode("ElementaryTypeName", { make_pair("name", Token::toString(_node.getTypeName())) }); + addJsonNode("ElementaryTypeName", { make_pair("name", Token::toString(_node.typeName())) }); return true; } bool ASTJsonConverter::visit(UserDefinedTypeName const& _node) { - addJsonNode("UserDefinedTypeName", { make_pair("name", _node.getName()) }); + addJsonNode("UserDefinedTypeName", { make_pair("name", _node.name()) }); return true; } @@ -208,7 +208,7 @@ bool ASTJsonConverter::visit(ExpressionStatement const&) bool ASTJsonConverter::visit(Assignment const& _node) { addJsonNode("Assignment", - { make_pair("operator", Token::toString(_node.getAssignmentOperator())), + { make_pair("operator", Token::toString(_node.assignmentOperator())), make_pair("type", getType(_node)) }, true); return true; @@ -251,7 +251,7 @@ bool ASTJsonConverter::visit(NewExpression const& _node) bool ASTJsonConverter::visit(MemberAccess const& _node) { addJsonNode("MemberAccess", - { make_pair("member_name", _node.getMemberName()), + { make_pair("member_name", _node.memberName()), make_pair("type", getType(_node)) }, true); return true; @@ -266,23 +266,23 @@ bool ASTJsonConverter::visit(IndexAccess const& _node) bool ASTJsonConverter::visit(Identifier const& _node) { addJsonNode("Identifier", - { make_pair("value", _node.getName()), make_pair("type", getType(_node)) }); + { make_pair("value", _node.name()), make_pair("type", getType(_node)) }); return true; } bool ASTJsonConverter::visit(ElementaryTypeNameExpression const& _node) { addJsonNode("ElementaryTypenameExpression", - { make_pair("value", Token::toString(_node.getTypeToken())), make_pair("type", getType(_node)) }); + { make_pair("value", Token::toString(_node.typeToken())), make_pair("type", getType(_node)) }); return true; } bool ASTJsonConverter::visit(Literal const& _node) { - char const* tokenString = Token::toString(_node.getToken()); + char const* tokenString = Token::toString(_node.token()); addJsonNode("Literal", { make_pair("string", (tokenString) ? tokenString : "null"), - make_pair("value", _node.getValue()), + make_pair("value", _node.value()), make_pair("type", getType(_node)) }); return true; } @@ -430,7 +430,7 @@ void ASTJsonConverter::process() string ASTJsonConverter::getType(Expression const& _expression) { - return (_expression.getType()) ? _expression.getType()->toString() : "Unknown"; + return (_expression.type()) ? _expression.type()->toString() : "Unknown"; } } |