summaryrefslogtreecommitdiffstats
path: root/generate_java_binder.cpp
diff options
context:
space:
mode:
authorChristopher Wiley <wiley@google.com>2016-01-29 11:10:49 -0800
committerChristopher Wiley <wiley@google.com>2016-01-29 19:43:47 +0000
commit3a9da170c8e8ab91841339cd0ee9b5edd12a80c6 (patch)
tree2c71a7db1aaaa6f861e99a0002df9ee300ee8ff1 /generate_java_binder.cpp
parent67502f1dd88923a2ad7a4e5cb76d572e6bb3304d (diff)
downloadandroid_system_tools_aidl-3a9da170c8e8ab91841339cd0ee9b5edd12a80c6.tar.gz
android_system_tools_aidl-3a9da170c8e8ab91841339cd0ee9b5edd12a80c6.tar.bz2
android_system_tools_aidl-3a9da170c8e8ab91841339cd0ee9b5edd12a80c6.zip
Update style in generate_java.*
- Add license notices - Adopt Google style conventions - remove string append(char* a, char* b) - remove using std::* declarations from headers - do not sprintf into a char buffer any longer Bug: None Change-Id: I42d95d25a6a88e87150bd9c7f1b79e26b9076c11 Test: compiles, unittests continue to pass
Diffstat (limited to 'generate_java_binder.cpp')
-rw-r--r--generate_java_binder.cpp20
1 files changed, 17 insertions, 3 deletions
diff --git a/generate_java_binder.cpp b/generate_java_binder.cpp
index 3cd9220..0b59ecd 100644
--- a/generate_java_binder.cpp
+++ b/generate_java_binder.cpp
@@ -1,3 +1,19 @@
+/*
+ * Copyright (C) 2016, The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
#include "generate_java.h"
#include <stdio.h>
@@ -18,7 +34,7 @@ class StubClass : public Class {
public:
StubClass(const Type* type, const InterfaceType* interfaceType,
JavaTypeNamespace* types);
- virtual ~StubClass();
+ virtual ~StubClass() = default;
Variable* transact_code;
Variable* transact_data;
@@ -101,8 +117,6 @@ StubClass::StubClass(const Type* type, const InterfaceType* interfaceType,
onTransact->statements->Add(new ReturnStatement(superCall));
}
-StubClass::~StubClass() {}
-
void StubClass::make_as_interface(const InterfaceType* interfaceType,
JavaTypeNamespace* types) {
Variable* obj = new Variable(types->IBinderType(), "obj");