diff --git a/android/sdk/build.gradle b/android/sdk/build.gradle index 3665675bba..85a6674f5b 100755 --- a/android/sdk/build.gradle +++ b/android/sdk/build.gradle @@ -1,3 +1,22 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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. + */ + buildscript { dependencies { classpath 'com.android.tools.build:gradle:2.3.3' diff --git a/android/sdk/gradle.properties b/android/sdk/gradle.properties index 08b9d65cdf..c621f8c509 100755 --- a/android/sdk/gradle.properties +++ b/android/sdk/gradle.properties @@ -1,3 +1,22 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + + # Project-wide Gradle settings. # IDE (e.g. Android Studio) users: diff --git a/android/sdk/proguard-rules.pro b/android/sdk/proguard-rules.pro index 73247bc730..957227f8c9 100755 --- a/android/sdk/proguard-rules.pro +++ b/android/sdk/proguard-rules.pro @@ -1,3 +1,22 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + + # Add project specific ProGuard rules here. # By default, the flags in this file are appended to flags specified # in /Users/ouy/Library/AndroidStudio/sdk/tools/proguard/proguard-android.txt @@ -19,4 +38,4 @@ -keep class com.taobao.weex.layout.** { *; } -keep class com.taobao.weex.WXSDKEngine { *; } -keep class com.taobao.weex.base.SystemMessageHandler { *; } --dontwarn com.taobao.weex.bridge.** \ No newline at end of file +-dontwarn com.taobao.weex.bridge.** diff --git a/android/sdk/publish.sh b/android/sdk/publish.sh index 4d70a7ce00..7700dd320b 100755 --- a/android/sdk/publish.sh +++ b/android/sdk/publish.sh @@ -1,2 +1,21 @@ #!/usr/bin/env bash -./gradlew clean assemble publish \ No newline at end of file + +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. + +./gradlew clean assemble publish diff --git a/weex_core/CMakeLists.txt b/weex_core/CMakeLists.txt index 2894e59436..b0dfca0dcf 100644 --- a/weex_core/CMakeLists.txt +++ b/weex_core/CMakeLists.txt @@ -1,3 +1,21 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# cmake_minimum_required(VERSION 3.4.1) project(WeexCore) add_subdirectory(Source) diff --git a/weex_core/Source/CMakeLists.txt b/weex_core/Source/CMakeLists.txt index 8b9df20db5..92b84beec6 100644 --- a/weex_core/Source/CMakeLists.txt +++ b/weex_core/Source/CMakeLists.txt @@ -1,3 +1,21 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# cmake_minimum_required(VERSION 3.4.1) set(WEEXCORE_LIBRARY_NAME weexcore) diff --git a/weex_core/Source/IPC/CMakeLists.txt b/weex_core/Source/IPC/CMakeLists.txt index f95e0b395e..beb1551f58 100644 --- a/weex_core/Source/IPC/CMakeLists.txt +++ b/weex_core/Source/IPC/CMakeLists.txt @@ -1,3 +1,22 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# + cmake_minimum_required(VERSION 3.4.1) set(IPC_LIBRARY_NAME weexipc) diff --git a/weex_core/Source/core/data_render/class_factory.cc b/weex_core/Source/core/data_render/class_factory.cc index bca5d9e8a8..4dccd81510 100644 --- a/weex_core/Source/core/data_render/class_factory.cc +++ b/weex_core/Source/core/data_render/class_factory.cc @@ -1,6 +1,21 @@ -// -// Created by chad on 2018/7/19. -// +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 "core/data_render/class_factory.h" #include "core/data_render/class.h" @@ -22,7 +37,7 @@ Value ClassFactory::CreateClassDescriptor(ClassDescriptor *p_super) { descs_.push_back(desc); return value; } - + Value ClassFactory::CreateArray() { Array *array = new Array(); Value value; @@ -31,7 +46,7 @@ Value ClassFactory::CreateArray() { arrays_.push_back(array); return value; } - + Value ClassFactory::CreateTable() { Table *table = new Table(); Value value; @@ -40,7 +55,7 @@ Value ClassFactory::CreateTable() { tables_.push_back(table); return value; } - + Value ClassFactory::ClassString() { ClassDescriptor *desc = NewClassString(); Value value; @@ -49,7 +64,7 @@ Value ClassFactory::ClassString() { descs_.push_back(desc); return value; } - + Value ClassFactory::ClassJSON() { ClassDescriptor *desc = NewClassJSON(); Value value; @@ -58,7 +73,7 @@ Value ClassFactory::ClassJSON() { descs_.push_back(desc); return value; } - + Value ClassFactory::ClassArray() { ClassDescriptor *desc = NewClassArray(); Value value; @@ -67,7 +82,7 @@ Value ClassFactory::ClassArray() { descs_.push_back(desc); return value; } - + Value ClassFactory::ClassObject() { ClassDescriptor *desc = NewClassOject(); Value value; @@ -76,7 +91,7 @@ Value ClassFactory::ClassObject() { descs_.push_back(desc); return value; } - + int ClassFactory::findDesc(const ClassDescriptor *desc) { int index = 0; for (auto d : descs_) { @@ -98,7 +113,7 @@ ClassInstance *ClassFactory::CreateClassInstanceFromSuper(ClassDescriptor *p_des } return inst; } - + Value ClassFactory::CreateClassInstance(ClassDescriptor *p_desc) { ClassInstance *inst = CreateClassInstanceFromSuper(p_desc); Value value; diff --git a/weex_core/Source/core/data_render/tokenizer.cc b/weex_core/Source/core/data_render/tokenizer.cc index a229196032..2d7ceec8e1 100644 --- a/weex_core/Source/core/data_render/tokenizer.cc +++ b/weex_core/Source/core/data_render/tokenizer.cc @@ -1,3 +1,22 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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 "core/data_render/tokenizer.h" #include "core/data_render/token.h" #include "core/data_render/scanner.h" @@ -16,12 +35,12 @@ namespace data_render { // TokenizerState implementation // ------------------------------- - + #ifdef __ANDROID__ #undef EOF static const char EOF = -1; #endif - + class TokenizerState { public: static std::unordered_map keywords; @@ -578,7 +597,7 @@ Token Tokenizer::ParseString(char delim) { } Token::Type type = delim == '`' ? Token::TEMPLATE : Token::STRING; - + if (utf8) { buffer = utf8_decode(buffer); } @@ -680,5 +699,5 @@ Token Tokenizer::ParseNumber(char start) { } } -} +} diff --git a/weex_core/Source/third_party/json11/CMakeLists.txt b/weex_core/Source/third_party/json11/CMakeLists.txt index 148c31ffed..0296ab309c 100644 --- a/weex_core/Source/third_party/json11/CMakeLists.txt +++ b/weex_core/Source/third_party/json11/CMakeLists.txt @@ -1,3 +1,22 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# + cmake_minimum_required(VERSION 3.4.1) set(JSON11_LIBRARY_NAME json11) diff --git a/weex_core/Source/weexjsc_version_script.txt b/weex_core/Source/weexjsc_version_script.txt index c34fbfce6c..69a28ec88e 100644 --- a/weex_core/Source/weexjsc_version_script.txt +++ b/weex_core/Source/weexjsc_version_script.txt @@ -1,3 +1,21 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# { global: *Inject_GCanvasFunc*; Java_com*; JNI_OnLoad; JNI_OnUnload; local: *; diff --git a/weex_core/Source/wson/CMakeLists.txt b/weex_core/Source/wson/CMakeLists.txt index a331a391dd..e42d6c75c7 100644 --- a/weex_core/Source/wson/CMakeLists.txt +++ b/weex_core/Source/wson/CMakeLists.txt @@ -1,3 +1,22 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# + cmake_minimum_required(VERSION 3.4.1) set(WSON_LIBRARY_NAME wson)