/** * {@inheritDoc} <br> * Returns the String representation of this JType. */ public String toString() { if (isUseJava50()) { if (getComponentType().isPrimitive()) { JPrimitiveType primitive = (JPrimitiveType) getComponentType(); return getName() + "<" + primitive.getWrapperName() + ">"; } return getName() + "<" + getComponentType().toString() + ">"; } return getName(); }
/** * Returns the instance name of this collection type. * * @return The instance name of this collection type. */ public String getInstanceName() { if (_instanceName != null) { if (isUseJava50()) { if (getComponentType().isPrimitive()) { JPrimitiveType primitive = (JPrimitiveType) getComponentType(); return _instanceName + "<" + primitive.getWrapperName() + ">"; } return _instanceName + "<" + getComponentType().toString() + ">"; } return _instanceName; } return toString(); }