1 26 27 package org.objectweb.openccm.ast.lib; 28 29 30 import org.objectweb.openccm.ast.api.TypeRef; 31 32 33 import org.omg.CORBA.ParameterMode ; 34 35 46 47 public class ParameterImpl 48 extends WithNameTypeRefImpl 49 implements org.objectweb.openccm.ast.api.Parameter 50 { 51 57 58 private ParameterMode mode_; 59 60 66 73 public 74 ParameterImpl(String name, 75 TypeRef type, 76 ParameterMode mode) 77 { 78 super(name, type); 80 81 mode_ = mode; 83 } 84 85 91 96 public org.omg.CORBA.ParameterDescription 97 getParameterDescription() 98 { 99 return new org.omg.CORBA.ParameterDescription ( 100 getName(), 101 org.objectweb.openccm.corba.TypeCodeUtils.getTC_void(), 102 getIDLType(), 103 mode_); 104 } 105 106 112 118 123 public int 124 getMode() 125 { 126 return mode_.value(); 127 } 128 129 134 public boolean isIn() 135 { 136 return mode_ == ParameterMode.PARAM_IN; 137 } 138 139 144 public boolean isOut() 145 { 146 return mode_ == ParameterMode.PARAM_OUT; 147 } 148 149 154 public boolean isInOut() 155 { 156 return mode_ == ParameterMode.PARAM_INOUT; 157 } 158 } 159 | Popular Tags |