1 // Copyright 2004-2007 Castle Project - http://www.castleproject.org/
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
7 // http://www.apache.org/licenses/LICENSE-2.0
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
15 namespace AspectSharp
.Lang
.AST
20 /// Summary description for AspectDefinition.
23 public class AspectDefinition
: NodeBase
26 private TargetTypeDefinition _targetType
;
27 private PointCutDefinitionCollection _pointcuts
= new PointCutDefinitionCollection();
28 private MixinDefinitionCollection _mixins
= new MixinDefinitionCollection();
30 public AspectDefinition(LexicalInfo info
, String name
) : base(info
)
38 set { _name = value; }
41 public TargetTypeDefinition TargetType
43 get { return _targetType; }
44 set { _targetType = value; }
47 public PointCutDefinitionCollection PointCuts
49 get { return _pointcuts; }
52 public MixinDefinitionCollection Mixins
54 get { return _mixins; }
57 public override void Accept(IVisitor visitor
)
59 visitor
.OnAspectDefinition(this);
62 public override string ToString()
67 public override bool Equals(object obj
)
69 return _name
.Equals(obj
);
72 public override int GetHashCode()
74 return _name
.GetHashCode();