1 2 package SOFA.SOFAnode.Made.CDL; 3 4 class CompProtOperand extends CompProtOper{ 5 public int mode; 6 public String operand; public String ifacename; 9 public CompProtOperand(String operand, String ifacename, int mode) { 10 super(CompProtKind.p_operand); 11 this.operand = operand; 12 this.ifacename = ifacename; 13 this.mode = mode; 14 } 15 16 public String toText() { 17 StringBuffer sb = new StringBuffer (); 18 if (mode == CompProtMode.pm_none) { sb.append(operand); 20 } else { if (mode == CompProtMode.pm_in) 22 sb.append("?"); 23 else 24 sb.append("!"); 25 sb.append(ifacename); 26 sb.append("."); 27 sb.append(operand); 28 } 29 return sb.toString(); 30 } 31 } 32 | Popular Tags |