コード例 #1
0
ファイル: Eq.cs プロジェクト: nilnul/nilnul._web_._LIB_
 public bool Equals(HostI1 x, HostI1 y)
 {
     return(nilnul.txt.eq_.CaseInsensitive.Singleton.Equals(x.ToString(), y.ToString()));
     //throw new NotImplementedException();
 }
コード例 #2
0
ファイル: Eq.cs プロジェクト: nilnul/nilnul._web_._LIB_
 public int GetHashCode(HostI1 obj)
 {
     return(0);
     //throw new NotImplementedException();
 }
コード例 #3
0
        public static nilnul.web._url._origin._authority._socket.host_.named_._domained._domain.Brand Brand(HostI1 host)
        {
            switch (host)
            {
            case nilnul.web._url._origin._authority._socket.host_.NamedI named:
                switch (named)
                {
                case nilnul.web._url._origin._authority._socket.host_.named_.DomainedI domained:
                    return(domained.domain.brand);

                    break;

                default:
                    throw new UnexpectedTypeException($"{host} is of type {typeof(nilnul.web._url._origin._authority._socket.host_.NamedI)} but not {typeof(nilnul.web._url._origin._authority._socket.host_.named_.DomainedI)}, such that no Brand can be retrieved.");
                    break;
                }
                break;

            default:
                throw new UnexpectedTypeException($"{host} is not of type {typeof(nilnul.web._url._origin._authority._socket.host_.NamedI)} (may be of type IP?), so no Brand can be retrieved.");
                break;
            }
        }