Exemplo n.º 1
0
        private Oid CoerceOid(object value)
        {
            if (value is Oid)
            {
                return((Oid)value);
            }

            if (value == null)
            {
                return(Oid.Null);
            }

            if (value is string)
            {
                return(Oid.FromToken((string)value, metaModel));
            }

            if (value is int)
            {
                return(new Oid(RelatedAsset, (int)value, null));
            }

            throw new OidException("Object is not convertible to an OID", value.ToString());
        }
Exemplo n.º 2
0
 public Oid GetOid(string token) => Oid.FromToken(token, _meta);
Exemplo n.º 3
0
 public Oid GetOid(string token)
 {
     return(Oid.FromToken(token, _meta));
 }
 public Oid GetOid(string token)
 {
     return(Oid.FromToken(token, metaModel));
 }