View Javadoc
1   package org.andromda.metafacades.uml14;
2   
3   import java.util.Collection;
4   import java.util.Collections;
5   import org.andromda.metafacades.uml.InstanceFacade;
6   import org.omg.uml.behavioralelements.commonbehavior.AttributeLink;
7   import org.omg.uml.behavioralelements.commonbehavior.Instance;
8   import org.omg.uml.foundation.core.Attribute;
9   
10  /**
11   * MetafacadeLogic implementation for org.andromda.metafacades.uml.AttributeLinkFacade.
12   *
13   * @see org.andromda.metafacades.uml.AttributeLinkFacade
14   * @author Bob Fields
15   */
16  public class AttributeLinkFacadeLogicImpl
17      extends AttributeLinkFacadeLogic
18  {
19      private static final long serialVersionUID = 34L;
20      /**
21       * @param metaObject
22       * @param context
23       */
24      public AttributeLinkFacadeLogicImpl(
25          AttributeLink metaObject,
26          String context)
27      {
28          super(metaObject, context);
29      }
30  
31      /**
32       * @see org.andromda.metafacades.uml.AttributeLinkFacade#getAttribute()
33       */
34      @Override
35      protected Attribute handleGetAttribute()
36      {
37          return metaObject.getAttribute();
38      }
39  
40      /**
41       * @see org.andromda.metafacades.uml.AttributeLinkFacade#getInstance()
42       */
43      @Override
44      protected Instance handleGetInstance()
45      {
46          return metaObject.getInstance();
47      }
48  
49      /**
50       * @see org.andromda.metafacades.uml.AttributeLinkFacade#getValue()
51       */
52      @Override
53      protected Instance handleGetValue()
54      {
55          return metaObject.getValue();
56      }
57  
58      /**
59       * @see org.andromda.metafacades.uml.AttributeLinkFacade#getValues()
60       */
61      @Override
62      protected Collection<InstanceFacade> handleGetValues()
63      {
64          return Collections.singleton(this.getValue());
65      }
66  }