/// <summary> /// Initializes a new instance of the <see cref="PropertyDeclarationTranslationUnit"/> class. /// </summary> /// <param name="name"></param> /// <param name="returnType"></param> /// <param name="visibility"></param> protected PropertyDeclarationTranslationUnit(ITranslationUnit name, ITranslationUnit returnType, VisibilityToken visibility) : base(name, visibility) { // We create empty groups this.getStatements = StatementsGroupTranslationUnit.Create(); this.setStatements = StatementsGroupTranslationUnit.Create(); this.type = returnType; this.hasGet = true; this.hasSet = true; }
/// <summary> /// Initializes a new instance of the <see cref="PropertyDeclarationTranslationUnit"/> class. /// </summary> /// <param name="name"></param> /// <param name="returnType"></param> /// <param name="modifiers"></param> protected PropertyDeclarationTranslationUnit(ITranslationUnit name, ITranslationUnit returnType, ModifierTokens modifiers) : base(name, modifiers) { // We create empty groups this.getStatements = StatementsGroupTranslationUnit.Create(); this.setStatements = StatementsGroupTranslationUnit.Create(); this.type = returnType; this.hasGet = true; this.hasSet = true; }
/// <summary> /// Initializes a new instance of the <see cref="BlockASTWalker"/> class. /// </summary> /// <param name="node"></param> /// <param name="statementsGroup"></param> /// <param name="semanticModel">The semantic model.</param> protected BlockASTWalker(CSharpSyntaxNode node, StatementsGroupTranslationUnit statementsGroup, SemanticModel semanticModel) : base(node, semanticModel) { var namespaceSyntaxNode = node as BlockSyntax; if (namespaceSyntaxNode == null) { throw new ArgumentException( string.Format("Specified node is not of type {0}", typeof(BlockSyntax).Name)); } if (statementsGroup == null) { throw new ArgumentNullException(nameof(statementsGroup)); } this.statementsGroup = statementsGroup; }
/// <summary> /// Copy initializes a new instance of the <see cref="BlockASTWalker"/> class. /// </summary> /// <param name="other"></param> public BlockASTWalker(BlockASTWalker other) : base(other) { this.statementsGroup = other.statementsGroup; }