Deviation parser and data model

Change-Id: I3cb3da5748057d0c2c9c99d7c3495643bc1ea243
diff --git a/compiler/plugin/maven/src/test/resources/InvalidDeviation/InvalidDeviationTarget.yang b/compiler/plugin/maven/src/test/resources/InvalidDeviation/InvalidDeviationTarget.yang
new file mode 100644
index 0000000..eff4726
--- /dev/null
+++ b/compiler/plugin/maven/src/test/resources/InvalidDeviation/InvalidDeviationTarget.yang
@@ -0,0 +1,16 @@
+module deviation-module5 {
+    yang-version 1;
+    namespace test:deviation5;
+    prefix On;
+    import "target" {
+        prefix "t";
+    }
+    deviation /t:ospf/t:intf-id {
+        description "desc";
+        reference "ref";
+         deviate delete {
+           units "units";
+           default "defaultValue";
+         }
+    }
+}
diff --git a/compiler/plugin/maven/src/test/resources/InvalidDeviation/deviationTarget.yang b/compiler/plugin/maven/src/test/resources/InvalidDeviation/deviationTarget.yang
new file mode 100644
index 0000000..cddfd0c
--- /dev/null
+++ b/compiler/plugin/maven/src/test/resources/InvalidDeviation/deviationTarget.yang
@@ -0,0 +1,14 @@
+module target {
+    yang-version 1;
+    namespace "test:deviation";
+    prefix test;
+    container ospf {
+        leaf process-id {
+            type "uint16";
+            units "seconds";
+            status current;
+            reference "RFC 6020";
+            default "1";
+         }
+    }
+}
\ No newline at end of file
diff --git a/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationAddStatement.yang b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationAddStatement.yang
new file mode 100644
index 0000000..5aa8ba5
--- /dev/null
+++ b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationAddStatement.yang
@@ -0,0 +1,22 @@
+module deviation-module2 {
+    yang-version 1;
+    namespace test:deviation2;
+    prefix On;
+    import "Test2" {
+        prefix "t";
+    }
+    deviation /t:ospf {
+        description "desc";
+        reference "ref";
+         deviate add {
+            must "/base:system";
+            config "false";
+         }
+    }
+
+    deviation /t:valid/t:invalid-interval {
+            description "desc";
+            reference "ref";
+            deviate not-supported;
+    }
+}
diff --git a/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationDeleteStatement.yang b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationDeleteStatement.yang
new file mode 100644
index 0000000..e129726
--- /dev/null
+++ b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationDeleteStatement.yang
@@ -0,0 +1,16 @@
+module deviation-module4 {
+    yang-version 1;
+    namespace test:deviation4;
+    prefix On;
+    import "Test2" {
+        prefix "t";
+    }
+    deviation /t:ospf/t:process-id {
+        description "desc";
+        reference "ref";
+         deviate delete {
+           units "units";
+           default "defaultValue";
+         }
+    }
+}
diff --git a/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationNotSupported.yang b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationNotSupported.yang
new file mode 100644
index 0000000..3cce4c5
--- /dev/null
+++ b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationNotSupported.yang
@@ -0,0 +1,19 @@
+module deviation-module {
+    yang-version 1;
+    namespace test:deviation;
+    prefix On;
+    import "Test2" {
+        prefix "t";
+    }
+    deviation /t:ospf {
+        description "desc";
+        reference "ref";
+        deviate not-supported;
+    }
+
+    deviation /t:valid/t:invalid-interval {
+            description "desc";
+            reference "ref";
+            deviate not-supported;
+    }
+}
diff --git a/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationReplaceStatement.yang b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationReplaceStatement.yang
new file mode 100644
index 0000000..6ed6545
--- /dev/null
+++ b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationReplaceStatement.yang
@@ -0,0 +1,21 @@
+module deviation-module3 {
+    yang-version 1;
+    namespace test:deviation3;
+    prefix On;
+    import "Test2" {
+        prefix "t";
+    }
+    deviation /t:ospf/t:process-id {
+        description "desc";
+        reference "ref";
+         deviate replace {
+            type int8;
+            units "units";
+            default "0";
+            config "true";
+            mandatory "true";
+            min-elements 0;
+            max-elements 3;
+         }
+    }
+}
diff --git a/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationTarget.yang b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationTarget.yang
new file mode 100644
index 0000000..e072c08
--- /dev/null
+++ b/compiler/plugin/maven/src/test/resources/deviationLinking/DeviationTarget.yang
@@ -0,0 +1,23 @@
+module Test2 {
+    yang-version 1;
+    namespace "test2:deviation";
+    prefix test;
+    container ospf {
+        leaf process-id {
+            type "uint16";
+            units "seconds";
+            status current;
+            reference "RFC 6020";
+            default "1";
+         }
+    }
+
+    container valid {
+        leaf invalid-interval {
+            type "uint16";
+            units "seconds";
+            status current;
+            reference "RFC 6020";
+         }
+    }
+}
\ No newline at end of file