Add Network Static Route D-bus Interface

Static routing provides the network administrator with full
control over the routing behavior of the BMC network.

This commit adds static route d-bus interface and properties
required.

Change-Id: Ib6abea1a9ce2f55cb54489c334b0072bf4fb726e
Signed-off-by: Ravi Teja <raviteja28031990@gmail.com>
diff --git a/gen/xyz/openbmc_project/Network/StaticRoute/Create/meson.build b/gen/xyz/openbmc_project/Network/StaticRoute/Create/meson.build
new file mode 100644
index 0000000..b3ad929
--- /dev/null
+++ b/gen/xyz/openbmc_project/Network/StaticRoute/Create/meson.build
@@ -0,0 +1,15 @@
+# Generated file; do not modify.
+generated_sources += custom_target(
+    'xyz/openbmc_project/Network/StaticRoute/Create__cpp'.underscorify(),
+    input: [ '../../../../../../yaml/xyz/openbmc_project/Network/StaticRoute/Create.interface.yaml',  ],
+    output: [ 'common.hpp', 'server.cpp', 'server.hpp', 'client.hpp',  ],
+    depend_files: sdbusplusplus_depfiles,
+    command: [
+        sdbuspp_gen_meson_prog, '--command', 'cpp',
+        '--output', meson.current_build_dir(),
+        '--tool', sdbusplusplus_prog,
+        '--directory', meson.current_source_dir() / '../../../../../../yaml',
+        'xyz/openbmc_project/Network/StaticRoute/Create',
+    ],
+)
+
diff --git a/gen/xyz/openbmc_project/Network/StaticRoute/meson.build b/gen/xyz/openbmc_project/Network/StaticRoute/meson.build
new file mode 100644
index 0000000..fd21c26
--- /dev/null
+++ b/gen/xyz/openbmc_project/Network/StaticRoute/meson.build
@@ -0,0 +1,30 @@
+# Generated file; do not modify.
+generated_sources += custom_target(
+    'xyz/openbmc_project/Network/StaticRoute__cpp'.underscorify(),
+    input: [ '../../../../../yaml/xyz/openbmc_project/Network/StaticRoute.interface.yaml',  ],
+    output: [ 'common.hpp', 'server.cpp', 'server.hpp', 'client.hpp',  ],
+    depend_files: sdbusplusplus_depfiles,
+    command: [
+        sdbuspp_gen_meson_prog, '--command', 'cpp',
+        '--output', meson.current_build_dir(),
+        '--tool', sdbusplusplus_prog,
+        '--directory', meson.current_source_dir() / '../../../../../yaml',
+        'xyz/openbmc_project/Network/StaticRoute',
+    ],
+)
+
+subdir('Create')
+generated_others += custom_target(
+    'xyz/openbmc_project/Network/StaticRoute/Create__markdown'.underscorify(),
+    input: [ '../../../../../yaml/xyz/openbmc_project/Network/StaticRoute/Create.interface.yaml',  ],
+    output: [ 'Create.md' ],
+    depend_files: sdbusplusplus_depfiles,
+    command: [
+        sdbuspp_gen_meson_prog, '--command', 'markdown',
+        '--output', meson.current_build_dir(),
+        '--tool', sdbusplusplus_prog,
+        '--directory', meson.current_source_dir() / '../../../../../yaml',
+        'xyz/openbmc_project/Network/StaticRoute/Create',
+    ],
+)
+
diff --git a/gen/xyz/openbmc_project/Network/meson.build b/gen/xyz/openbmc_project/Network/meson.build
index 966f916..d0bbcab 100644
--- a/gen/xyz/openbmc_project/Network/meson.build
+++ b/gen/xyz/openbmc_project/Network/meson.build
@@ -90,6 +90,21 @@
     ],
 )
 
+subdir('StaticRoute')
+generated_others += custom_target(
+    'xyz/openbmc_project/Network/StaticRoute__markdown'.underscorify(),
+    input: [ '../../../../yaml/xyz/openbmc_project/Network/StaticRoute.interface.yaml',  ],
+    output: [ 'StaticRoute.md' ],
+    depend_files: sdbusplusplus_depfiles,
+    command: [
+        sdbuspp_gen_meson_prog, '--command', 'markdown',
+        '--output', meson.current_build_dir(),
+        '--tool', sdbusplusplus_prog,
+        '--directory', meson.current_source_dir() / '../../../../yaml',
+        'xyz/openbmc_project/Network/StaticRoute',
+    ],
+)
+
 subdir('SystemConfiguration')
 generated_others += custom_target(
     'xyz/openbmc_project/Network/SystemConfiguration__markdown'.underscorify(),
diff --git a/yaml/xyz/openbmc_project/Network/StaticRoute.interface.yaml b/yaml/xyz/openbmc_project/Network/StaticRoute.interface.yaml
new file mode 100644
index 0000000..127d1ea
--- /dev/null
+++ b/yaml/xyz/openbmc_project/Network/StaticRoute.interface.yaml
@@ -0,0 +1,33 @@
+description: >
+    This interface defines network static routes
+
+properties:
+    - name: Destination
+      type: string
+      description: >
+          The value of this property shall be a destination IP address, only
+          destination network IP address allowed. it does not allow hostname.
+      errors:
+          - xyz.openbmc_project.Common.Error.NotAllowed
+
+    - name: Gateway
+      type: string
+      description: >
+          The value of this property shall be a next hop address assigned to the
+          ethernet interface to reach destination address.
+      errors:
+          - xyz.openbmc_project.Common.Error.NotAllowed
+
+    - name: PrefixLength
+      type: size
+      description: >
+          This is the number of network bits in the address.
+      errors:
+          - xyz.openbmc_project.Common.Error.NotAllowed
+
+    - name: ProtocolType
+      type: enum[xyz.openbmc_project.Network.IP.Protocol]
+      description: >
+          Protocol type can be IPv4 or IPv6 etc.
+      errors:
+          - xyz.openbmc_project.Common.Error.NotAllowed
diff --git a/yaml/xyz/openbmc_project/Network/StaticRoute/Create.interface.yaml b/yaml/xyz/openbmc_project/Network/StaticRoute/Create.interface.yaml
new file mode 100644
index 0000000..e03b411
--- /dev/null
+++ b/yaml/xyz/openbmc_project/Network/StaticRoute/Create.interface.yaml
@@ -0,0 +1,29 @@
+description: >
+methods:
+    - name: StaticRoute
+      description: >
+          Create a static route entry.
+      parameters:
+          - name: Destination
+            type: string
+            description: >
+                Destination Address.
+          - name: Gateway
+            type: string
+            description: >
+                Next hop address to reach destination address
+          - name: PrefixLength
+            type: size
+            description: >
+                Number of network bits in the address
+          - name: ProtocolType
+            type: enum[xyz.openbmc_project.Network.IP.Protocol]
+            description: >
+                protocol type can be IPv4 or IPv6 etc.
+      returns:
+          - name: Path
+            type: object_path
+            description: >
+                The path for the created static route object.
+      errors:
+          - xyz.openbmc_project.Common.Error.InvalidArgument