Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 1 | /* |
Brian O'Connor | 0f7908b | 2016-04-09 01:19:45 -0700 | [diff] [blame] | 2 | * Copyright 2016-present Open Networking Laboratory |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 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.yangutils.datamodel; |
| 17 | |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 18 | import org.onosproject.yangutils.datamodel.exceptions.DataModelException; |
| 19 | import org.onosproject.yangutils.parser.Parsable; |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 20 | import org.onosproject.yangutils.utils.YangConstructType; |
Vinod Kumar S | 9f26ae5 | 2016-03-23 15:30:27 +0530 | [diff] [blame] | 21 | |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 22 | import static org.onosproject.yangutils.utils.YangConstructType.CHOICE_DATA; |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 23 | |
| 24 | /*- |
| 25 | * Reference RFC 6020. |
| 26 | * |
| 27 | * The "choice" statement defines a set of alternatives, only one of |
| 28 | * which may exist at any one time. The argument is an identifier, |
| 29 | * followed by a block of sub-statements that holds detailed choice |
| 30 | * information. The identifier is used to identify the choice node in |
| 31 | * the schema tree. A choice node does not exist in the data tree. |
| 32 | * |
| 33 | * A choice consists of a number of branches, defined with the "case" |
| 34 | * sub-statement. Each branch contains a number of child nodes. The |
| 35 | * nodes from at most one of the choice's branches exist at the same |
| 36 | * time. |
| 37 | * |
| 38 | * The choice's sub-statements |
| 39 | * |
| 40 | * +--------------+---------+-------------+------------------+ |
| 41 | * | substatement | section | cardinality |data model mapping| |
| 42 | * +--------------+---------+-------------+------------------+ |
| 43 | * | anyxml | 7.10 | 0..n |-not supported | |
| 44 | * | case | 7.9.2 | 0..n |-YangChoice | |
| 45 | * | config | 7.19.1 | 0..1 |-boolean | |
| 46 | * | container | 7.5 | 0..n |-child case nodes | |
| 47 | * | default | 7.9.3 | 0..1 |-string | |
| 48 | * | description | 7.19.3 | 0..1 |-string | |
| 49 | * | if-feature | 7.18.2 | 0..n |-TODO | |
| 50 | * | leaf | 7.6 | 0..n |-child case nodes | |
| 51 | * | leaf-list | 7.7 | 0..n |-child case nodes | |
| 52 | * | list | 7.8 | 0..n |-child case nodes | |
| 53 | * | mandatory | 7.9.4 | 0..1 |-string | |
| 54 | * | reference | 7.19.4 | 0..1 |-string | |
| 55 | * | status | 7.19.2 | 0..1 |-string | |
| 56 | * | when | 7.19.5 | 0..1 |-TODO | |
| 57 | * +--------------+---------+-------------+------------------+ |
| 58 | */ |
| 59 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 60 | * Represents data model node to maintain information defined in YANG choice. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 61 | */ |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 62 | public class YangChoice extends YangNode implements YangCommonInfo, Parsable, CollisionDetector { |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 63 | |
| 64 | /** |
| 65 | * Name of choice. |
| 66 | */ |
| 67 | private String name; |
| 68 | |
| 69 | /** |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 70 | * If the choice represents config data. |
| 71 | */ |
| 72 | private boolean isConfig; |
| 73 | |
| 74 | /** |
| 75 | * Reference RFC 6020. |
| 76 | * |
| 77 | * The "default" statement indicates if a case should be considered as the |
| 78 | * default if no child nodes from any of the choice's cases exist. The |
| 79 | * argument is the identifier of the "case" statement. If the "default" |
| 80 | * statement is missing, there is no default case. |
| 81 | * |
| 82 | * The "default" statement MUST NOT be present on choices where "mandatory" |
| 83 | * is true. |
| 84 | * |
| 85 | * The default case is only important when considering the default values of |
| 86 | * nodes under the cases. The default values for nodes under the default |
| 87 | * case are used if none of the nodes under any of the cases are present. |
| 88 | * |
| 89 | * There MUST NOT be any mandatory nodes directly under the default case. |
| 90 | * |
| 91 | * Default values for child nodes under a case are only used if one of the |
| 92 | * nodes under that case is present, or if that case is the default case. If |
| 93 | * none of the nodes under a case are present and the case is not the |
| 94 | * default case, the default values of the cases' child nodes are ignored. |
| 95 | * |
| 96 | * the default case to be used if no case members is present. |
| 97 | */ |
| 98 | private String defaultCase; |
| 99 | |
| 100 | /** |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 101 | * Description of choice. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 102 | */ |
| 103 | private String description; |
| 104 | |
| 105 | /** |
| 106 | * Reference RFC 6020. |
| 107 | * |
| 108 | * The "mandatory" statement, which is optional, takes as an argument the |
| 109 | * string "true" or "false", and puts a constraint on valid data. If |
| 110 | * "mandatory" is "true", at least one node from exactly one of the choice's |
| 111 | * case branches MUST exist. |
| 112 | * |
| 113 | * If not specified, the default is "false". |
| 114 | * |
| 115 | * The behavior of the constraint depends on the type of the choice's |
| 116 | * closest ancestor node in the schema tree which is not a non-presence |
| 117 | * container: |
| 118 | * |
| 119 | * o If this ancestor is a case node, the constraint is enforced if any |
| 120 | * other node from the case exists. |
| 121 | * |
| 122 | * o Otherwise, it is enforced if the ancestor node exists. |
| 123 | */ |
| 124 | private String mandatory; |
| 125 | |
| 126 | /** |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 127 | * Reference of the choice. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 128 | */ |
| 129 | private String reference; |
| 130 | |
| 131 | /** |
| 132 | * Status of the node. |
| 133 | */ |
| 134 | private YangStatusType status; |
| 135 | |
| 136 | /** |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 137 | * Create a choice node. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 138 | */ |
| 139 | public YangChoice() { |
| 140 | super(YangNodeType.CHOICE_NODE); |
| 141 | } |
| 142 | |
Vinod Kumar S | 9f26ae5 | 2016-03-23 15:30:27 +0530 | [diff] [blame] | 143 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 144 | * Returns the choice name. |
Vinod Kumar S | 9f26ae5 | 2016-03-23 15:30:27 +0530 | [diff] [blame] | 145 | * |
| 146 | * @return choice name |
| 147 | */ |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 148 | @Override |
| 149 | public String getName() { |
| 150 | return name; |
| 151 | } |
| 152 | |
Vinod Kumar S | 9f26ae5 | 2016-03-23 15:30:27 +0530 | [diff] [blame] | 153 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 154 | * Sets the choice name. |
Vinod Kumar S | 9f26ae5 | 2016-03-23 15:30:27 +0530 | [diff] [blame] | 155 | * |
| 156 | * @param name choice name |
| 157 | */ |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 158 | @Override |
| 159 | public void setName(String name) { |
| 160 | this.name = name; |
| 161 | } |
| 162 | |
| 163 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 164 | * Returns config flag. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 165 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 166 | * @return the config flag |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 167 | */ |
| 168 | public boolean isConfig() { |
| 169 | return isConfig; |
| 170 | } |
| 171 | |
| 172 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 173 | * Sets config flag. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 174 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 175 | * @param isCfg the config flag |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 176 | */ |
| 177 | public void setConfig(boolean isCfg) { |
| 178 | isConfig = isCfg; |
| 179 | } |
| 180 | |
| 181 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 182 | * Returns the default case. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 183 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 184 | * @return the default case |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 185 | */ |
| 186 | public String getDefaultCase() { |
| 187 | return defaultCase; |
| 188 | } |
| 189 | |
| 190 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 191 | * Sets the default case. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 192 | * |
| 193 | * @param defaultCase the default case to set |
| 194 | */ |
| 195 | public void setDefaultCase(String defaultCase) { |
| 196 | this.defaultCase = defaultCase; |
| 197 | } |
| 198 | |
| 199 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 200 | * Returns the mandatory status. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 201 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 202 | * @return the mandatory status |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 203 | */ |
| 204 | public String getMandatory() { |
| 205 | return mandatory; |
| 206 | } |
| 207 | |
| 208 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 209 | * Sets the mandatory status. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 210 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 211 | * @param mandatory the mandatory status |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 212 | */ |
| 213 | public void setMandatory(String mandatory) { |
| 214 | this.mandatory = mandatory; |
| 215 | } |
| 216 | |
| 217 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 218 | * Returns the description. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 219 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 220 | * @return the description |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 221 | */ |
Bharat saraswal | 5e3c45c | 2016-02-22 22:15:21 +0530 | [diff] [blame] | 222 | @Override |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 223 | public String getDescription() { |
| 224 | return description; |
| 225 | } |
| 226 | |
| 227 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 228 | * Sets the description. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 229 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 230 | * @param description set the description |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 231 | */ |
Bharat saraswal | 5e3c45c | 2016-02-22 22:15:21 +0530 | [diff] [blame] | 232 | @Override |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 233 | public void setDescription(String description) { |
| 234 | this.description = description; |
| 235 | } |
| 236 | |
| 237 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 238 | * Returns the textual reference. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 239 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 240 | * @return the reference |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 241 | */ |
Bharat saraswal | 5e3c45c | 2016-02-22 22:15:21 +0530 | [diff] [blame] | 242 | @Override |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 243 | public String getReference() { |
| 244 | return reference; |
| 245 | } |
| 246 | |
| 247 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 248 | * Sets the textual reference. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 249 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 250 | * @param reference the reference to set |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 251 | */ |
Bharat saraswal | 5e3c45c | 2016-02-22 22:15:21 +0530 | [diff] [blame] | 252 | @Override |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 253 | public void setReference(String reference) { |
| 254 | this.reference = reference; |
| 255 | } |
| 256 | |
| 257 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 258 | * Returns the status. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 259 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 260 | * @return the status |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 261 | */ |
Bharat saraswal | 5e3c45c | 2016-02-22 22:15:21 +0530 | [diff] [blame] | 262 | @Override |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 263 | public YangStatusType getStatus() { |
| 264 | return status; |
| 265 | } |
| 266 | |
| 267 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 268 | * Sets the status. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 269 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 270 | * @param status the status to set |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 271 | */ |
Bharat saraswal | 5e3c45c | 2016-02-22 22:15:21 +0530 | [diff] [blame] | 272 | @Override |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 273 | public void setStatus(YangStatusType status) { |
| 274 | this.status = status; |
| 275 | } |
| 276 | |
| 277 | /** |
| 278 | * Returns the type of the data. |
| 279 | * |
Vidyashree Rama | 1396065 | 2016-04-26 15:06:06 +0530 | [diff] [blame] | 280 | * @return choice data |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 281 | */ |
Bharat saraswal | 5e3c45c | 2016-02-22 22:15:21 +0530 | [diff] [blame] | 282 | @Override |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 283 | public YangConstructType getYangConstructType() { |
Vidyashree Rama | 1396065 | 2016-04-26 15:06:06 +0530 | [diff] [blame] | 284 | return CHOICE_DATA; |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 285 | } |
| 286 | |
| 287 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 288 | * Validates the data on entering the corresponding parse tree node. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 289 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 290 | * @throws DataModelException a violation of data model rules |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 291 | */ |
Bharat saraswal | 5e3c45c | 2016-02-22 22:15:21 +0530 | [diff] [blame] | 292 | @Override |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 293 | public void validateDataOnEntry() throws DataModelException { |
| 294 | // TODO auto-generated method stub, to be implemented by parser |
| 295 | } |
| 296 | |
| 297 | /** |
Bharat saraswal | 63f26fb | 2016-04-05 15:13:44 +0530 | [diff] [blame] | 298 | * Validates the data on exiting the corresponding parse tree node. |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 299 | * |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 300 | * @throws DataModelException a violation of data model rules |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 301 | */ |
Bharat saraswal | 5e3c45c | 2016-02-22 22:15:21 +0530 | [diff] [blame] | 302 | @Override |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 303 | public void validateDataOnExit() throws DataModelException { |
| 304 | // TODO auto-generated method stub, to be implemented by parser |
| 305 | } |
| 306 | |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 307 | @Override |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 308 | public void detectCollidingChild(String identifierName, YangConstructType dataType) throws DataModelException { |
| 309 | |
Vinod Kumar S | 9f26ae5 | 2016-03-23 15:30:27 +0530 | [diff] [blame] | 310 | if (this.getParent() instanceof YangCase && dataType != YangConstructType.CASE_DATA) { |
| 311 | ((CollisionDetector) getParent()).detectCollidingChild(identifierName, dataType); |
| 312 | } |
| 313 | YangNode node = getChild(); |
| 314 | while (node != null) { |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 315 | if (node instanceof CollisionDetector) { |
| 316 | ((CollisionDetector) node).detectSelfCollision(identifierName, dataType); |
| 317 | } |
| 318 | node = node.getNextSibling(); |
| 319 | } |
| 320 | } |
| 321 | |
| 322 | @Override |
| 323 | public void detectSelfCollision(String identifierName, YangConstructType dataType) throws DataModelException { |
| 324 | |
| 325 | if (dataType == CHOICE_DATA) { |
Vinod Kumar S | 9f26ae5 | 2016-03-23 15:30:27 +0530 | [diff] [blame] | 326 | if (getName().equals(identifierName)) { |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 327 | throw new DataModelException("YANG file error: Identifier collision detected in choice \"" + |
Vinod Kumar S | 9f26ae5 | 2016-03-23 15:30:27 +0530 | [diff] [blame] | 328 | getName() + "\""); |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 329 | } |
| 330 | return; |
| 331 | } |
| 332 | |
Vinod Kumar S | 9f26ae5 | 2016-03-23 15:30:27 +0530 | [diff] [blame] | 333 | YangNode node = getChild(); |
| 334 | while (node != null) { |
Gaurav Agrawal | db828bd | 2016-02-27 03:57:50 +0530 | [diff] [blame] | 335 | if (node instanceof CollisionDetector) { |
| 336 | ((CollisionDetector) node).detectSelfCollision(identifierName, dataType); |
| 337 | } |
| 338 | node = node.getNextSibling(); |
| 339 | } |
| 340 | } |
Vinod Kumar S | 5a39e01 | 2016-02-16 01:37:16 +0530 | [diff] [blame] | 341 | } |