當前位置: 首頁>>代碼示例>>C#>>正文


C# CodeModel.CodeUnitProxy類代碼示例

本文整理匯總了C#中StyleCop.CSharp.CodeModel.CodeUnitProxy的典型用法代碼示例。如果您正苦於以下問題:C# CodeUnitProxy類的具體用法?C# CodeUnitProxy怎麽用?C# CodeUnitProxy使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


CodeUnitProxy類屬於StyleCop.CSharp.CodeModel命名空間,在下文中一共展示了CodeUnitProxy類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: Interface

 /// <summary>
 /// Initializes a new instance of the Interface class.
 /// </summary>
 /// <param name="proxy">Proxy object for the interface.</param>
 /// <param name="name">The name of the interface.</param>
 /// <param name="attributes">The list of attributes attached to this element.</param>
 /// <param name="typeConstraints">The list of type constraints on the class, if any.</param>
 /// <param name="unsafeCode">Indicates whether the element resides within a block of unsafe code.</param>
 internal Interface(CodeUnitProxy proxy, string name, ICollection<Attribute> attributes, ICollection<TypeParameterConstraintClause> typeConstraints, bool unsafeCode)
     : base(proxy, ElementType.Interface, name, attributes, typeConstraints, unsafeCode)
 {
     Param.AssertNotNull(proxy, "proxy");
     Param.AssertValidString(name, "name");
     Param.Ignore(attributes, typeConstraints, unsafeCode);
 }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:15,代碼來源:Interface.cs

示例2: Statement

 /// <summary>
 /// Initializes a new instance of the Statement class.
 /// </summary>
 /// <param name="proxy">Proxy object for the statement.</param>
 /// <param name="type">The type of the statement.</param>
 internal Statement(CodeUnitProxy proxy, StatementType type) 
     : base(proxy, (int)type)
 {
     Param.AssertNotNull(proxy, "proxy");
     Param.Ignore(type);
     CsLanguageService.Debug.Assert(System.Enum.IsDefined(typeof(StatementType), this.StatementType), "The type is invalid.");
 }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:12,代碼來源:Statement.cs

示例3: Enum

 /// <summary>
 /// Initializes a new instance of the Enum class.
 /// </summary>
 /// <param name="proxy">Proxy object for the enum.</param>
 /// <param name="name">The name of the enum.</param>
 /// <param name="attributes">The list of attributes attached to this element.</param>
 /// <param name="unsafeCode">Indicates whether the element resides within a block of unsafe code.</param>
 internal Enum(CodeUnitProxy proxy, string name, ICollection<Attribute> attributes, bool unsafeCode)
     : base(proxy, ElementType.Enum, name, attributes, unsafeCode)
 {
     Param.AssertNotNull(proxy, "proxy");
     Param.AssertValidString(name, "name");
     Param.Ignore(attributes, unsafeCode);
 }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:14,代碼來源:Enum.cs

示例4: GenericTypeToken

        /// <summary>
        /// Initializes a new instance of the GenericTypeToken class.
        /// </summary>
        /// <param name="proxy">Proxy object for the statement.</param>
        internal GenericTypeToken(CodeUnitProxy proxy)
            : base(proxy)
        {
            Param.AssertGreaterThanOrEqualTo(proxy.Children.Count, 3, "childTokens");

            this.IsGeneric = true;
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:11,代碼來源:GenericTypeToken.cs

示例5: Expression

 /// <summary>
 /// Initializes a new instance of the Expression class.
 /// </summary>
 /// <param name="proxy">Proxy object for the expression.</param>
 /// <param name="type">The type of the expression.</param>
 internal Expression(CodeUnitProxy proxy, int type)
     : base(proxy, type)
 {
     Param.AssertNotNull(proxy, "proxy");
     Param.Ignore(type);
     CsLanguageService.Debug.Assert(System.Enum.IsDefined(typeof(ExpressionType), this.ExpressionType), "The type is invalid.");
 }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:12,代碼來源:Expression.cs

示例6: PreprocessorDirective

        /// <summary>
        /// Initializes a new instance of the PreprocessorDirective class.
        /// </summary>
        /// <param name="proxy">Proxy object for the directive.</param>
        /// <param name="preprocessorType">The type of the preprocessor.</param>
        internal PreprocessorDirective(CodeUnitProxy proxy, PreprocessorType preprocessorType)
            : base(proxy, (int)preprocessorType)
        {
            Param.AssertNotNull(proxy, "proxy");
            Param.Ignore(preprocessorType);

            CsLanguageService.Debug.Assert(System.Enum.IsDefined(typeof(PreprocessorType), this.PreprocessorType), "The type is invalid.");
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:PreprocessorDirective.cs

示例7: ThrowStatement

        /// <summary>
        /// Initializes a new instance of the ThrowStatement class.
        /// </summary>
        /// <param name="proxy">Proxy object for the statement.</param>
        /// <param name="thrownExpression">The expression being thrown, if any.</param>
        internal ThrowStatement(CodeUnitProxy proxy, Expression thrownExpression)
            : base(proxy, StatementType.Throw)
        {
            Param.Ignore(proxy);
            Param.Ignore(thrownExpression);

            this.thrownExpression.Value = thrownExpression;
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:ThrowStatement.cs

示例8: LabelStatement

        /// <summary>
        /// Initializes a new instance of the LabelStatement class.
        /// </summary>
        /// <param name="proxy">Proxy object for the statement.</param>
        /// <param name="identifier">The label identifier.</param>
        internal LabelStatement(CodeUnitProxy proxy, LiteralExpression identifier)
            : base(proxy, StatementType.Label)
        {
            Param.AssertNotNull(proxy, "proxy");
            Param.AssertNotNull(identifier, "identifier");

            this.identifier.Value = identifier;
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:LabelStatement.cs

示例9: UnsafeStatement

        /// <summary>
        /// Initializes a new instance of the UnsafeStatement class.
        /// </summary>
        /// <param name="proxy">Proxy object for the statement.</param>
        /// <param name="body">The body of the try-statement.</param>
        internal UnsafeStatement(CodeUnitProxy proxy, BlockStatement body)
            : base(proxy, StatementType.Unsafe)
        {
            Param.AssertNotNull(proxy, "proxy");
            Param.AssertNotNull(body, "body");

            this.body.Value = body;
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:UnsafeStatement.cs

示例10: QueryWhereClause

        /// <summary>
        /// Initializes a new instance of the QueryWhereClause class.
        /// </summary>
        /// <param name="proxy">Proxy object for the clause.</param>
        /// <param name="expression">The expression.</param>
        internal QueryWhereClause(CodeUnitProxy proxy, Expression expression)
            : base(proxy, QueryClauseType.Where)
        {
            Param.AssertNotNull(proxy, "proxy");
            Param.AssertNotNull(expression, "expression");

            this.expression.Value = expression;
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:QueryWhereClause.cs

示例11: UsingStatement

        /// <summary>
        /// Initializes a new instance of the UsingStatement class.
        /// </summary>
        /// <param name="proxy">Proxy object for the statement.</param>
        /// <param name="resource">The resource aquisition expression declared in the using statement.</param>
        internal UsingStatement(CodeUnitProxy proxy, Expression resource)
            : base(proxy, StatementType.Using)
        {
            Param.AssertNotNull(proxy, "proxy");
            Param.AssertNotNull(resource, "resource");

            this.resource.Value = resource;
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:UsingStatement.cs

示例12: ComplexToken

        /// <summary>
        /// Initializes a new instance of the ComplexToken class.
        /// </summary>
        /// <param name="proxy">Proxy object for the statement.</param>
        /// <param name="tokenType">The type of the token.</param>
        internal ComplexToken(CodeUnitProxy proxy, TokenType tokenType)
            : base(proxy, tokenType)
        {
            Param.AssertNotNull(proxy, "proxy");
            Param.Ignore(tokenType);

            this.IsComplexToken = true;
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:ComplexToken.cs

示例13: VariableDeclarationStatement

        /// <summary>
        /// Initializes a new instance of the VariableDeclarationStatement class.
        /// </summary>
        /// <param name="proxy">Proxy object for the statement.</param>
        /// <param name="expression">The inner expression.</param>
        internal VariableDeclarationStatement(CodeUnitProxy proxy, VariableDeclarationExpression expression)
            : base(proxy, StatementType.VariableDeclaration)
        {
            Param.AssertNotNull(proxy, "proxy");
            Param.AssertNotNull(expression, "expression");

            this.expression.Value = expression;
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:VariableDeclarationStatement.cs

示例14: ArgumentList

        /// <summary>
        /// Initializes a new instance of the ArgumentList class.
        /// </summary>
        /// <param name="proxy">The proxy class.</param>
        /// <param name="arguments">The collection of arguments within the list.</param>
        internal ArgumentList(CodeUnitProxy proxy, IEnumerable<Argument> arguments)
            : base(proxy, CodeUnitType.ArgumentList)
        {
            Param.AssertNotNull(proxy, "proxy");
            Param.AssertNotNull(arguments, "arguments");

            this.arguments.Value = new List<Argument>(arguments);
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:ArgumentList.cs

示例15: StackallocExpression

        /// <summary>
        /// Initializes a new instance of the StackallocExpression class.
        /// </summary>
        /// <param name="proxy">Proxy object for the expression.</param>
        /// <param name="type">The array type.</param>
        internal StackallocExpression(CodeUnitProxy proxy, ArrayAccessExpression type)
            : base(proxy, ExpressionType.Stackalloc)
        {
            Param.AssertNotNull(proxy, "proxy");
            Param.AssertNotNull(type, "type");

            this.type.Value = type;
        }
開發者ID:jonthegiant,項目名稱:StyleCop,代碼行數:13,代碼來源:StackallocExpression.cs


注:本文中的StyleCop.CSharp.CodeModel.CodeUnitProxy類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。