コード例 #1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="TypeATerm"/> class.
        /// </summary>
        /// <param name="factory">The factory that created this term.</param>
        /// <param name="name">The name.</param>
        /// <param name="annotations">The annotations of the term.</param>
        public TypeATerm(ITermFactory factory, IStringTerm name, IReadOnlyCollection <ITerm> annotations)
            : base(factory, annotations)
        {
            #region Contract
            if (name == null)
            {
                throw new ArgumentNullException(nameof(name));
            }
            #endregion

            this.Name     = name;
            this.subterms = new SubtermCollection(this);
        }
コード例 #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="EntityATerm"/> class.
        /// </summary>
        /// <param name="factory">The factory that created this term.</param>
        /// <param name="name">The name.</param>
        /// <param name="properties">The properties.</param>
        /// <param name="annotations">The annotations of the term.</param>
        public EntityATerm(ITermFactory factory, IStringTerm name, IListTerm <IPropertyTerm> properties, IReadOnlyCollection <ITerm> annotations)
            : base(factory, annotations)
        {
            #region Contract
            if (name == null)
            {
                throw new ArgumentNullException(nameof(name));
            }
            if (properties == null)
            {
                throw new ArgumentNullException(nameof(properties));
            }
            #endregion

            this.Name       = name;
            this.Properties = properties;
            this.subterms   = new SubtermCollection(this);
        }
コード例 #3
0
        /// <summary>
        /// Initializes a new instance of the <see cref="ModuleATerm"/> class.
        /// </summary>
        /// <param name="factory">The factory that created this term.</param>
        /// <param name="name">The name.</param>
        /// <param name="definitions">The definitions.</param>
        /// <param name="annotations">The annotations of the term.</param>
        public ModuleATerm(ITermFactory factory, IStringTerm name, IListTerm <IEntityTerm> definitions, IReadOnlyCollection <ITerm> annotations)
            : base(factory, annotations)
        {
            #region Contract
            if (name == null)
            {
                throw new ArgumentNullException(nameof(name));
            }
            if (definitions == null)
            {
                throw new ArgumentNullException(nameof(definitions));
            }
            #endregion

            this.Name        = name;
            this.Definitions = definitions;
            this.subterms    = new SubtermCollection(this);
        }