1 package org.andromda.core.simpleuml; 2 3 import java.util.List; 4 5 import org.omg.uml.foundation.datatypes.VisibilityKind; 6 7 /*** 8 * 9 * Implements an enumeration of the four types of operation/attribute visibilities in 10 * java: private,public, protected and 'package' level visibility. 11 * 12 * @author <A HREF="http://www.amowers.com">Anthony Mowers</A> 13 * 14 */ 15 public class JavaVisibilityEnum implements VisibilityKind 16 { 17 public final static VisibilityKind PRIVATE = new JavaVisibilityEnum("private"); 18 public final static VisibilityKind PUBLIC = new JavaVisibilityEnum("public"); 19 public final static VisibilityKind PROTECTED = new JavaVisibilityEnum("protected"); 20 public final static VisibilityKind PACKAGE = new JavaVisibilityEnum(""); 21 22 private String visibility; 23 24 private JavaVisibilityEnum(String visibility) 25 { 26 this.visibility = visibility; 27 } 28 29 public String toString() 30 { 31 return visibility; 32 } 33 34 /*** 35 * @see javax.jmi.reflect.RefEnum#refTypeName() 36 */ 37 public List refTypeName() 38 { 39 return null; 40 } 41 42 }