Refactor TypedSchemaNode
[yangtools.git] / yang / yang-model-api / src / main / java / org / opendaylight / yangtools / yang / model / api / LeafSchemaNode.java
index db930d218280a9c308a146585340b82ac6a8ca1b..1c6d6d3587521cb4eeb2a4bedecc78a115f53fdc 100644 (file)
@@ -1,27 +1,22 @@
-/*\r
- * Copyright (c) 2013 Cisco Systems, Inc. and others.  All rights reserved.\r
- *\r
- * This program and the accompanying materials are made available under the\r
- * terms of the Eclipse Public License v1.0 which accompanies this distribution,\r
- * and is available at http://www.eclipse.org/legal/epl-v10.html\r
- */\r
-package org.opendaylight.yangtools.yang.model.api;\r
-\r
-/**\r
- * Interface describing YANG 'leaf' statement.\r
- * <p>\r
- * The 'leaf' statement is used to define a leaf node in the schema tree.\r
- * </p>\r
- */\r
-public interface LeafSchemaNode extends DataSchemaNode {\r
-\r
-    /**\r
-     * @return type of this leaf\r
-     */\r
-    TypeDefinition<?> getType();\r
-\r
-    String getDefault();\r
-\r
-    String getUnits();\r
-\r
-}\r
+/*
+ * Copyright (c) 2013 Cisco Systems, Inc. and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api;
+
+/**
+ * Interface describing YANG <code>leaf</code> statement.
+ *
+ * <p>
+ * The 'leaf' statement is used to define a leaf node in the schema tree.
+ *
+ * <p>
+ * Since we are presenting the effective model of the world, the information dictated by 'default' and 'units'
+ * substatements is captured in the type returned via {@link #getType()}.
+ */
+public interface LeafSchemaNode extends TypedDataSchemaNode, MandatoryAware, MustConstraintAware {
+
+}