/** * Append a text to an @-param tag. * * @param aParam * Param name * @return Comment part */ @Nonnull public JSCommentPart addParam (@Nonnull final JSVar aParam) { return addParam (aParam.name ()); }
@Nonnull public static JSInvocation invoke (@Nonnull final JSVar aVar) { return new JSInvocation ((IJSExpression) null, aVar.name ()); }
@Nonnull @Nonempty public final String name () { return m_sName != null ? m_sName : m_aVar.name (); }
@Nonnull public static JSInvocation invoke (@Nonnull final JSVar aVar) { return new JSInvocation ((IJSExpression) null, aVar.name ()); }
@Nonnull @Nonempty public final String name () { return m_sName != null ? m_sName : m_aVar.name (); }
/** * Append a text to an @-param tag. * * @param aParam * Param name * @return Comment part */ @Nonnull public JSCommentPart addParam (@Nonnull final JSVar aParam) { return addParam (aParam.name ()); }
@Nonnull @Override public JSFieldVar name (@Nonnull @Nonempty final String sNewName) throws JSNameAlreadyExistsException { final String sOldName = name (); if (!sOldName.equals (sNewName)) { // make sure that the new name is available final JSFieldVar aExistingField = m_aOwnerClass.getFieldOfName (sNewName); if (aExistingField != null) throw new JSNameAlreadyExistsException (aExistingField); m_aOwnerClass.removeField (this); super.name (sNewName); m_aOwnerClass.addField (this); } return this; }
@Nonnull @Override public JSFieldVar name (@Nonnull @Nonempty final String sNewName) throws JSNameAlreadyExistsException { final String sOldName = name (); if (!sOldName.equals (sNewName)) { // make sure that the new name is available final JSFieldVar aExistingField = m_aOwnerClass.getFieldOfName (sNewName); if (aExistingField != null) throw new JSNameAlreadyExistsException (aExistingField); m_aOwnerClass.removeField (this); super.name (sNewName); m_aOwnerClass.addField (this); } return this; }