Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2016 Open Networking Laboratory |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | package org.onosproject.teyang.utils.topology; |
| 17 | |
Henry Yu | 4b4a7eb | 2016-11-09 20:07:53 -0500 | [diff] [blame^] | 18 | import org.onosproject.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.network.topology.rev20151208.ietfnetworktopology |
| 19 | .networks.network.node.augmentedndnode.TerminationPoint; |
Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 20 | |
| 21 | /** |
| 22 | * The termination point translations. |
| 23 | */ |
| 24 | public final class TerminationPointConverter { |
| 25 | |
Henry Yu | 4b4a7eb | 2016-11-09 20:07:53 -0500 | [diff] [blame^] | 26 | private static final String E_NULL_TE_SUBSYSTEM_TP = |
| 27 | "TeSubsystem terminationPoint object cannot be null"; |
| 28 | private static final String E_NULL_YANG_TP = |
| 29 | "YANG terminationPoint object cannot be null"; |
Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 30 | |
| 31 | // no instantiation |
| 32 | private TerminationPointConverter() { |
| 33 | } |
| 34 | |
| 35 | /** |
| 36 | * TerminationPoint object translation from TE Topology subsystem to YANG. |
| 37 | * |
Henry Yu | 4b4a7eb | 2016-11-09 20:07:53 -0500 | [diff] [blame^] | 38 | * @param teSubsystem TE Topology subsystem termination point |
| 39 | * @return Termination point in YANG Java data structure |
Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 40 | */ |
| 41 | public static TerminationPoint teSubsystem2YangTerminationPoint( |
Henry Yu | 4b4a7eb | 2016-11-09 20:07:53 -0500 | [diff] [blame^] | 42 | org.onosproject.tetopology.management.api.node.TerminationPoint teSubsystem) { |
Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 43 | |
Henry Yu | 4b4a7eb | 2016-11-09 20:07:53 -0500 | [diff] [blame^] | 44 | //TODO: implementation to be submitted as a separate review |
| 45 | return null; |
Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 46 | } |
| 47 | |
Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 48 | |
| 49 | /** |
| 50 | * TerminationPoint object translation from YANG to TE Topology subsystem. |
| 51 | * |
Henry Yu | 4b4a7eb | 2016-11-09 20:07:53 -0500 | [diff] [blame^] | 52 | * @param yangTp Termination point in YANG Java data structure |
| 53 | * @return TerminationPoint TE Topology subsystem termination point |
Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 54 | */ |
| 55 | public static org.onosproject.tetopology.management.api.node.TerminationPoint |
Henry Yu | 4b4a7eb | 2016-11-09 20:07:53 -0500 | [diff] [blame^] | 56 | yang2teSubsystemTerminationPoint(TerminationPoint yangTp) { |
Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 57 | |
Henry Yu | 4b4a7eb | 2016-11-09 20:07:53 -0500 | [diff] [blame^] | 58 | // TODO: implementation to be submitted as separate review |
| 59 | return null; |
Yixiao Chen | 39828a6 | 2016-09-14 14:37:06 -0400 | [diff] [blame] | 60 | } |
| 61 | |
| 62 | } |