⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 testentitybean.java

📁 Jboss s J2EE Sample
💻 JAVA
📖 第 1 页 / 共 2 页
字号:
   *   * @ejb:persistent-field   *   * @jboss:column-name name="First_Name"   **/   public abstract String getFirstName();      /**   * Set the TestEntity's FirstName.   *   * @param pFirstName The FirstName of this TestEntity.  Is set at creation time.   **/   public abstract void setFirstName( String pFirstName );      /**   * Retrieve the TestEntity's LastName.   *   * @return Returns an int representing the LastName of this TestEntity.   *   * @ejb:persistent-field   *   * @jboss:column-name name="Last_Name"   **/   public abstract String getLastName();      /**   * Set the TestEntity's LastName.   *   * @param pLastName The LastName of this TestEntity.  Is set at creation time.   **/   public abstract void setLastName( String pLastName );      /**   * Retrieve the TestEntity's Password.   *   * @return Returns an int representing the Password of this TestEntity.   *   * @ejb:persistent-field   *   * @jboss:column-name name="Password"   **/   public abstract String getPassword();      /**   * Set the TestEntity's Password.   *   * @param pPassword The Password of this TestEntity   **/   public abstract void setPassword( String pPassword );      /**   * Retrieve the TestEntity's Email.   *   * @return Returns an int representing the Email of this TestEntity.   *   * @ejb:persistent-field   *   * @jboss:column-name name="Email"   **/   public abstract String getEmail();      /**   * Set the TestEntity's Email.   *   * @param pEmail The Email of this TestEntity.  Is set at creation time.   **/   public abstract void setEmail( String pEmail );      /**   * @return Returns the Address of this TestEntity   *   * @ejb:persistent-field   *   * @jboss:column-name name="Address"   **/   public abstract String getAddress();      /**   * Specify the Address of this TestEntity   *   * @param pAddress Address of this TestEntity   **/   public abstract void setAddress( String pAddress );      /**   * @return Returns the City of this TestEntity   *   * @ejb:persistent-field   *   * @jboss:column-name name="City"   **/   public abstract String getCity();      /**   * Specify the City of this TestEntity   *   * @param pCity City of this TestEntity   **/   public abstract void setCity( String pCity );      /**   * @return Returns the ZIP of this TestEntity   *   * @ejb:persistent-field   *   * @jboss:column-name name="ZIP"   **/   public abstract String getZIP();      /**   * Specify the ZIP of this TestEntity   *   * @param pZIP ZIP of this TestEntity   **/   public abstract void setZIP( String pZIP );      /**   * @return Returns the State of this TestEntity   *   * @ejb:persistent-field   *   * @jboss:column-name name="State"   **/   public abstract String getState();      /**   * Specify the State of this TestEntity   *   * @param pState State of this TestEntity   **/   public abstract void setState( String pState );      /**   * @return Returns the Country of this TestEntity   *   * @ejb:persistent-field   *   * @jboss:column-name name="Country"   **/   public abstract String getCountry();      /**   * Specify the Country of this TestEntity   *   * @param pCountry Country of this TestEntity   **/   public abstract void setCountry( String pCountry );      /**   * @return Returns the creation date of this TestEntity   *   * @ejb:persistent-field   *   * @jboss:column-name name="Creation_Date"   **/   public abstract Date getCreationDate();      /**   * Specify the creation date of this TestEntity   *   * @param pCreationDate Date of the creation of this TestEntity   **/   public abstract void setCreationDate( Date pCreationDate );      /**   * @return Returns the modification date of this TestEntity   *   * @ejb:persistent-field   *   * @jboss:column-name name="Modification_Date"   **/   public abstract Date getModificationDate();      /**   * Specify the modification date of this TestEntity   *   * @param pModificationDate Date of the modification of this TestEntity   **/   public abstract void setModificationDate( Date pModificationDate );      // -------------------------------------------------------------------------   // Framework Callbacks   // -------------------------------------------------------------------------        /**   * Create a TestEntity based on the supplied TestEntity Value Object.   *   * @param pTestEntity The data used to create the TestEntity.   *   * @throws InvalidValueException If one of the values are not correct,   *                               this will not roll back the transaction   *                               because the caller has the chance to   *                               fix the problem and try again   * @throws EJBException If no new unique ID could be retrieved this will   *                      rollback the transaction because there is no   *                      hope to try again   * @throws CreateException Because we have to do so (EJB spec.)   *   * @ejb:create-method view-type="remote"   **/   public TestEntityPK ejbCreate( TestEntityData pTestEntity )      throws         InvalidValueException,         EJBException,         CreateException   {      // Clone the given Value Object to keep changed private      TestEntityData lData = (TestEntityData) pTestEntity.clone();      try {         // Each title must have a unique id to identify itself within the DB         lData.setId( generateUniqueId() );      }      catch( ServiceUnavailableException se ) {         // The unique id could not be set therefore terminate the transaction         // by throwing a system exception         throw new EJBException( se.getMessage() );      }      // Save the new TestEntity      setValueObject( lData );      // This is only possible in CMPs. Otherwise return a valid PK.      return null;   }      public void ejbPostCreate( TestEntityData pTestEntity )   {   }      public void setEntityContext( EntityContext lContext )   {      mContext = lContext;   }      public void unsetEntityContext()   {      mContext = null;   }      public void ejbActivate()   {   }      public void ejbPassivate()   {   }      public void ejbLoad()   {   }      public void ejbStore()   {   }      public void ejbRemove()      throws         RemoveException   {   }}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -