1 21 package org.jacorb.ir.gui.typesystem.remote; 22 23 26 27 import java.util.*; 28 import org.omg.CORBA.*; 29 import javax.swing.tree.*; 30 31 public class IRAttribute 32 extends IRNodeWithType 33 { 34 37 public IRAttribute ( ) { 38 super(); 39 } 40 41 44 45 public IRAttribute( IRObject irObject) 46 { 47 super(irObject); 48 AttributeDef attributeDef = 49 AttributeDefHelper.narrow(irObject); 50 setAssociatedTypeSystemNode(RemoteTypeSystem.createTypeSystemNode(attributeDef.type_def())); 51 } 52 53 56 57 public String getInstanceNodeTypeName ( ) 58 { 59 String result = super.getInstanceNodeTypeName(); 60 if ( AttributeDefHelper.narrow((org.omg.CORBA.Object )irObject).mode().value() == 61 AttributeMode._ATTR_READONLY) 62 { 63 result = "readonly" + " " + result; 64 } 65 return result; 66 } 67 68 71 public static String nodeTypeName() 72 { 73 return "attribute"; 74 } 75 } 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | Popular Tags |