*/
package org.opendaylight.yangtools.yang.model.api.type;
-import org.opendaylight.yangtools.yang.common.QName;
+import java.util.Set;
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.IdentitySchemaNode;
import org.opendaylight.yangtools.yang.model.api.TypeDefinition;
/**
- *
* Contains method for getting data from <code>identityref</code> built-in YANG
* type.
- *
*/
public interface IdentityrefTypeDefinition extends TypeDefinition<IdentityrefTypeDefinition> {
-
/**
- * Returns QName of the identity to which the instance of this type refers.
- *
- * @return QName of referenced identity which is specified with the
- * <code>identity</code> YANG statement
+ * Returns identity to which the instance of this type refers.
+ *
+ * @deprecated use {@link #getIdentities()} instead
+ *
+ * @return identity which is specified with the <code>identity</code> YANG
+ * statement
*/
- public QName getIdentity();
+ @Deprecated
+ IdentitySchemaNode getIdentity();
+ /**
+ * Returns the set of identities this reference points to.
+ *
+ * @return set of identities to which the instance of this type refers (in YANG 1.1 models) or a set containing
+ * just one identity (in YANG 1.0 models)
+ */
+ @Nonnull Set<IdentitySchemaNode> getIdentities();
}