@Retention(value=RUNTIME) @Target(value={FIELD,METHOD}) @Documented @Inherited public @interface DaoManager
RepositoryManager into a annotated
RepositoryManager.RepositoryManager 到有注釋的RepositoryManager.DaoAnnotationBeanPostProcessor bean in your spring
context.DaoAnnotationBeanPostProcessor bean 就可以了.@DaoManager(Entity.class) public RepositoryManagerWill inject and create a RepositoryManager implementation innto entityManager.entityManager;
| Modifier and Type | Fields and Description |
|---|---|
static String |
LOCK_NONE |
static String |
LOCK_OPTIMISTIC |
static String |
LOCK_OPTIMISTIC_FORCE_INCREMENT |
static String |
LOCK_PESSIMISTIC_FORCE_INCREMENT |
static String |
LOCK_PESSIMISTIC_READ |
static String |
LOCK_PESSIMISTIC_WRITE |
static String |
LOCK_READ |
static String |
LOCK_WRITE |
| Modifier and Type | Optional Element and Description |
|---|---|
boolean |
autoRegister
|
Class<? extends RepositoryManager> |
baseManagerType |
String |
daoName
Naming dao object to be turned into a Spring bean in case of an
autodetected component.
|
String |
name
Naming object to be turned into a Spring bean in case of an autodetected
component.
|
Class |
value
Class assoicated with
RepositoryManager. |
public static final String LOCK_WRITE
public static final String LOCK_OPTIMISTIC
public static final String LOCK_OPTIMISTIC_FORCE_INCREMENT
public static final String LOCK_PESSIMISTIC_READ
public static final String LOCK_PESSIMISTIC_WRITE
public static final String LOCK_PESSIMISTIC_FORCE_INCREMENT
public abstract Class<? extends RepositoryManager> baseManagerType
RepositoryManagerpublic abstract boolean autoRegister
value's simple class name suffix
with "Manager" if not assigned name, also
register dao bean with value's simple class name suffix
with "Dao" if not assigned daoNamename,則自動以value的類別名稱加上"Manager"註冊,
同樣地,若未指定daoName,亦會以value的類別名稱加上"Dao"註冊,Copyright © 2020. All rights reserved.