Package org.silverpeas.components.resourcesmanager.model

## Class Resource

- java.lang.Object
- - org.silverpeas.core.persistence.datasource.model.jpa.AbstractJpaEntity<E,​I>
  - - org.silverpeas.core.persistence.datasource.model.jpa.BasicJpaEntity<Resource,​org.silverpeas.core.persistence.datasource.model.identifier.UniqueLongIdentifier>
    - - org.silverpeas.components.resourcesmanager.model.Resource

- All Implemented Interfaces:
    `Serializable`, `org.silverpeas.core.persistence.datasource.model.IdentifiableEntity`

      @Entity
      public class Resource
      extends org.silverpeas.core.persistence.datasource.model.jpa.BasicJpaEntity<Resource,​org.silverpeas.core.persistence.datasource.model.identifier.UniqueLongIdentifier>

  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `Resource()` |
    `Resource​(Long id, Category category, String name, String description, String createrId, String updaterId, String instanceId, boolean bookable)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `boolean` | `equals​(Object obj)` |
    `Category` | `getCategory()` |
    `Long` | `getCategoryId()` |
    `String` | `getCreaterId()` |
    `Date` | `getCreationDate()` |
    `String` | `getDescription()` |
    `Long` | `getIdAsLong()` |
    `String` | `getIdAsString()` |
    `String` | `getInstanceId()` |
    `List<ResourceValidator>` | `getManagers()` |
    `String` | `getName()` |
    `String` | `getStatus()` |
    `Date` | `getUpdateDate()` |
    `String` | `getUpdaterId()` |
    `int` | `hashCode()` |
    `boolean` | `isBookable()` |
    `boolean` | `isRefused()` |
    `boolean` | `isValidated()` |
    `boolean` | `isValidationRequired()` |
    `void` | `merge​(Resource resource)` |
    `protected void` | `performBeforePersist()` |
    `void` | `performBeforeUpdate()` |
    `void` | `setBookable​(boolean bookable)` |
    `void` | `setCategory​(Category category)` |
    `void` | `setCreaterId​(String createrId)` |
    `void` | `setCreationDate​(Date creationDate)` |
    `void` | `setDescription​(String description)` |
    `void` | `setInstanceId​(String instanceId)` |
    `void` | `setManagers​(List<ResourceValidator> managers)` |
    `void` | `setName​(String name)` |
    `void` | `setStatus​(String status)` |
    `void` | `setUpdateDate​(Date updateDate)` |
    `void` | `setUpdaterId​(String updaterId)` |
    `String` | `toString()` |

    - ### Methods inherited from class org.silverpeas.core.persistence.datasource.model.jpa.BasicJpaEntity

      `performBeforeRemove`

    - ### Methods inherited from class org.silverpeas.core.persistence.datasource.model.jpa.AbstractJpaEntity

      `getId, getNativeId, isPersisted, setId`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### Resource

          public Resource()

    - #### Resource

          public Resource​(Long id,
                          Category category,
                          String name,
                          String description,
                          String createrId,
                          String updaterId,
                          String instanceId,
                          boolean bookable)

  - ### Method Detail

    - #### performBeforePersist

          protected void performBeforePersist()

      Overrides:
        `performBeforePersist` in class `org.silverpeas.core.persistence.datasource.model.jpa.BasicJpaEntity<Resource,​org.silverpeas.core.persistence.datasource.model.identifier.UniqueLongIdentifier>`

    - #### performBeforeUpdate

          public void performBeforeUpdate()

      Overrides:
        `performBeforeUpdate` in class `org.silverpeas.core.persistence.datasource.model.jpa.BasicJpaEntity<Resource,​org.silverpeas.core.persistence.datasource.model.identifier.UniqueLongIdentifier>`

    - #### isBookable

          public boolean isBookable()

    - #### setBookable

          public void setBookable​(boolean bookable)

    - #### getCreaterId

          public String getCreaterId()

    - #### setCreaterId

          public void setCreaterId​(String createrId)

    - #### getCreationDate

          public Date getCreationDate()

    - #### setCreationDate

          public void setCreationDate​(Date creationDate)

    - #### getUpdateDate

          public Date getUpdateDate()

    - #### setUpdateDate

          public void setUpdateDate​(Date updateDate)

    - #### getDescription

          public String getDescription()

    - #### setDescription

          public void setDescription​(String description)

    - #### getIdAsLong

          public Long getIdAsLong()

    - #### getIdAsString

          public String getIdAsString()

    - #### getCategoryId

          public Long getCategoryId()

    - #### setCategory

          public void setCategory​(Category category)

    - #### getCategory

          public Category getCategory()

    - #### getInstanceId

          public String getInstanceId()

    - #### setInstanceId

          public void setInstanceId​(String instanceId)

    - #### getName

          public String getName()

    - #### setName

          public void setName​(String name)

    - #### getUpdaterId

          public String getUpdaterId()

    - #### setUpdaterId

          public void setUpdaterId​(String updaterId)

    - #### getManagers

          public List<ResourceValidator> getManagers()

    - #### setManagers

          public void setManagers​(List<ResourceValidator> managers)

    - #### merge

          public void merge​(Resource resource)

    - #### equals

          public boolean equals​(Object obj)

      Overrides:
        `equals` in class `org.silverpeas.core.persistence.datasource.model.jpa.AbstractJpaEntity<Resource,​org.silverpeas.core.persistence.datasource.model.identifier.UniqueLongIdentifier>`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `org.silverpeas.core.persistence.datasource.model.jpa.AbstractJpaEntity<Resource,​org.silverpeas.core.persistence.datasource.model.identifier.UniqueLongIdentifier>`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### isValidated

          public boolean isValidated()

    - #### isRefused

          public boolean isRefused()

    - #### isValidationRequired

          public boolean isValidationRequired()

    - #### getStatus

          public String getStatus()

    - #### setStatus

          public void setStatus​(String status)