From: ying.yunlong Date: Tue, 15 Aug 2017 07:55:47 +0000 (+0800) Subject: Add code logic of tosca parser X-Git-Tag: v1.0.0~192 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F67%2F7567%2F1;p=vfc%2Fnfvo%2Flcm.git Add code logic of tosca parser In ONAP R1, VFC project will use nfv tosca parser to parse csar package, init the directory and file at the first time. Change-Id: I826c8f485e0254832ca3b5b4d2808410eb5b7687 Issue-ID: VFC-97 Signed-off-by: ying.yunlong --- diff --git a/.gitignore b/.gitignore index 821f62a6..67c551bb 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ logs/*.log -*.pyc \ No newline at end of file +*.pyc +.idea \ No newline at end of file diff --git a/lcm/pub/utils/toscaparser/__init__.py b/lcm/pub/utils/toscaparser/__init__.py new file mode 100644 index 00000000..a2564f74 --- /dev/null +++ b/lcm/pub/utils/toscaparser/__init__.py @@ -0,0 +1,19 @@ +# Copyright 2017 ZTE Corporation. +# +# 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. + +def parse_nsd(path, input_parameters=[]): + pass + +def parse_vnfd(path, input_parameters=[]): + pass \ No newline at end of file diff --git a/lcm/pub/utils/toscaparser/convert.py b/lcm/pub/utils/toscaparser/convert.py new file mode 100644 index 00000000..5399fe66 --- /dev/null +++ b/lcm/pub/utils/toscaparser/convert.py @@ -0,0 +1,13 @@ +# Copyright 2017 ZTE Corporation. +# +# 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. diff --git a/lcm/pub/utils/toscaparser/parser.py b/lcm/pub/utils/toscaparser/parser.py new file mode 100644 index 00000000..5399fe66 --- /dev/null +++ b/lcm/pub/utils/toscaparser/parser.py @@ -0,0 +1,13 @@ +# Copyright 2017 ZTE Corporation. +# +# 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.