diff --git a/schema/globals.yml b/schema/globals.yml index 71a9ce7..bf538b0 100644 --- a/schema/globals.yml +++ b/schema/globals.yml @@ -40,7 +40,7 @@ properties: vrf: description: VRF id. - type: number + type: integer ipv4-unreachable: description: Define a list of non-interface specific UNREACHABLE routes. @@ -58,4 +58,4 @@ properties: vrf: description: VRF id. - type: number + type: integer diff --git a/schema/interface.ipv4.yml b/schema/interface.ipv4.yml index bb05396..c72d1ab 100644 --- a/schema/interface.ipv4.yml +++ b/schema/interface.ipv4.yml @@ -30,7 +30,7 @@ properties: vrf: description: VRF id. - type: number + type: integer gateway: description: This option defines the static IPv4 gateway of the logical interface. @@ -55,7 +55,7 @@ properties: vrf: description: VRF id. - type: number + type: integer metric: description: Optional metric value (define a NH route's weight / metric). @@ -77,7 +77,7 @@ properties: vrf: description: VRF id. - type: number + type: integer multicast: type: object properties: diff --git a/schemareader.uc b/schemareader.uc index 40f4c65..a456421 100644 --- a/schemareader.uc +++ b/schemareader.uc @@ -532,8 +532,8 @@ function instantiateGlobals(location, value, errors) { } function parseVrf(location, value, errors) { - if (!(type(value) in [ "int", "double" ])) - push(errors, [ location, "must be of type number" ]); + if (type(value) != "int") + push(errors, [ location, "must be of type integer" ]); return value; } @@ -588,8 +588,8 @@ function instantiateGlobals(location, value, errors) { } function parseVrf(location, value, errors) { - if (!(type(value) in [ "int", "double" ])) - push(errors, [ location, "must be of type number" ]); + if (type(value) != "int") + push(errors, [ location, "must be of type integer" ]); return value; } @@ -2549,8 +2549,8 @@ function instantiateInterfaceIpv4(location, value, errors) { } function parseVrf(location, value, errors) { - if (!(type(value) in [ "int", "double" ])) - push(errors, [ location, "must be of type number" ]); + if (type(value) != "int") + push(errors, [ location, "must be of type integer" ]); return value; } @@ -2622,8 +2622,8 @@ function instantiateInterfaceIpv4(location, value, errors) { } function parseVrf(location, value, errors) { - if (!(type(value) in [ "int", "double" ])) - push(errors, [ location, "must be of type number" ]); + if (type(value) != "int") + push(errors, [ location, "must be of type integer" ]); return value; } @@ -2689,8 +2689,8 @@ function instantiateInterfaceIpv4(location, value, errors) { } function parseVrf(location, value, errors) { - if (!(type(value) in [ "int", "double" ])) - push(errors, [ location, "must be of type number" ]); + if (type(value) != "int") + push(errors, [ location, "must be of type integer" ]); return value; } diff --git a/ucentral.schema.full.json b/ucentral.schema.full.json index fa0b4e0..945e050 100644 --- a/ucentral.schema.full.json +++ b/ucentral.schema.full.json @@ -429,7 +429,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" } } } @@ -450,7 +450,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" } } } @@ -1340,7 +1340,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" } } } @@ -1369,7 +1369,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" }, "metric": { "description": "Optional metric value (define a NH route's weight / metric).", @@ -1394,7 +1394,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" } } } diff --git a/ucentral.schema.json b/ucentral.schema.json index 5d42805..d7f4f9c 100644 --- a/ucentral.schema.json +++ b/ucentral.schema.json @@ -251,7 +251,7 @@ ] }, "vrf": { - "type": "number" + "type": "integer" } } } @@ -269,7 +269,7 @@ ] }, "vrf": { - "type": "number" + "type": "integer" } } } @@ -1094,7 +1094,7 @@ ] }, "vrf": { - "type": "number" + "type": "integer" } } } @@ -1119,7 +1119,7 @@ ] }, "vrf": { - "type": "number" + "type": "integer" }, "metric": { "type": "number" @@ -1140,7 +1140,7 @@ ] }, "vrf": { - "type": "number" + "type": "integer" } } } diff --git a/ucentral.schema.pretty.json b/ucentral.schema.pretty.json index d09c2ac..1a5db46 100644 --- a/ucentral.schema.pretty.json +++ b/ucentral.schema.pretty.json @@ -280,7 +280,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" } } } @@ -301,7 +301,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" } } } @@ -1248,7 +1248,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" } } } @@ -1277,7 +1277,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" }, "metric": { "description": "Optional metric value (define a NH route's weight / metric).", @@ -1302,7 +1302,7 @@ }, "vrf": { "description": "VRF id.", - "type": "number" + "type": "integer" } } }