@ProviderType public interface AccountPersistence extends BasePersistence<Account>
Caching information and settings can be found in portal.properties
AccountUtil
Modifier and Type | Method and Description |
---|---|
void |
cacheResult(Account account)
Caches the account in the entity cache if it is enabled.
|
void |
cacheResult(java.util.List<Account> accounts)
Caches the accounts in the entity cache if it is enabled.
|
int |
countAll()
Returns the number of accounts.
|
int |
countByU_A(long userId,
java.lang.String address)
Returns the number of accounts where userId = ? and address = ?.
|
int |
countByUserId(long userId)
Returns the number of accounts where userId = ?.
|
Account |
create(long accountId)
Creates a new account with the primary key.
|
Account |
fetchByPrimaryKey(long accountId)
Returns the account with the primary key or returns
null if it could not be found. |
java.util.Map<java.io.Serializable,Account> |
fetchByPrimaryKeys(java.util.Set<java.io.Serializable> primaryKeys) |
Account |
fetchByU_A(long userId,
java.lang.String address)
Returns the account where userId = ? and address = ? or returns
null if it could not be found. |
Account |
fetchByU_A(long userId,
java.lang.String address,
boolean useFinderCache)
Returns the account where userId = ? and address = ? or returns
null if it could not be found, optionally using the finder cache. |
Account |
fetchByUserId_First(long userId,
OrderByComparator<Account> orderByComparator)
Returns the first account in the ordered set where userId = ?.
|
Account |
fetchByUserId_Last(long userId,
OrderByComparator<Account> orderByComparator)
Returns the last account in the ordered set where userId = ?.
|
java.util.List<Account> |
findAll()
Returns all the accounts.
|
java.util.List<Account> |
findAll(int start,
int end)
Returns a range of all the accounts.
|
java.util.List<Account> |
findAll(int start,
int end,
OrderByComparator<Account> orderByComparator)
Returns an ordered range of all the accounts.
|
java.util.List<Account> |
findAll(int start,
int end,
OrderByComparator<Account> orderByComparator,
boolean useFinderCache)
Returns an ordered range of all the accounts.
|
Account |
findByPrimaryKey(long accountId)
Returns the account with the primary key or throws a
NoSuchAccountException if it could not be found. |
Account |
findByU_A(long userId,
java.lang.String address)
Returns the account where userId = ? and address = ? or throws a
NoSuchAccountException if it could not be found. |
Account |
findByUserId_First(long userId,
OrderByComparator<Account> orderByComparator)
Returns the first account in the ordered set where userId = ?.
|
Account |
findByUserId_Last(long userId,
OrderByComparator<Account> orderByComparator)
Returns the last account in the ordered set where userId = ?.
|
Account[] |
findByUserId_PrevAndNext(long accountId,
long userId,
OrderByComparator<Account> orderByComparator)
Returns the accounts before and after the current account in the ordered set where userId = ?.
|
java.util.List<Account> |
findByUserId(long userId)
Returns all the accounts where userId = ?.
|
java.util.List<Account> |
findByUserId(long userId,
int start,
int end)
Returns a range of all the accounts where userId = ?.
|
java.util.List<Account> |
findByUserId(long userId,
int start,
int end,
OrderByComparator<Account> orderByComparator)
Returns an ordered range of all the accounts where userId = ?.
|
java.util.List<Account> |
findByUserId(long userId,
int start,
int end,
OrderByComparator<Account> orderByComparator,
boolean useFinderCache)
Returns an ordered range of all the accounts where userId = ?.
|
java.util.Set<java.lang.String> |
getBadColumnNames() |
Account |
remove(long accountId)
Removes the account with the primary key from the database.
|
void |
removeAll()
Removes all the accounts from the database.
|
Account |
removeByU_A(long userId,
java.lang.String address)
Removes the account where userId = ? and address = ? from the database.
|
void |
removeByUserId(long userId)
Removes all the accounts where userId = ? from the database.
|
Account |
updateImpl(Account account) |
clearCache, clearCache, clearCache, clearCache, closeSession, countWithDynamicQuery, countWithDynamicQuery, fetchByPrimaryKey, findByPrimaryKey, findWithDynamicQuery, findWithDynamicQuery, findWithDynamicQuery, flush, getCurrentSession, getDataSource, getListeners, getModelClass, openSession, processException, registerListener, remove, remove, setDataSource, unregisterListener, update, update
java.util.Map<java.io.Serializable,Account> fetchByPrimaryKeys(java.util.Set<java.io.Serializable> primaryKeys)
fetchByPrimaryKeys
in interface BasePersistence<Account>
java.util.List<Account> findByUserId(long userId)
userId
- the user IDjava.util.List<Account> findByUserId(long userId, int start, int end)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil#ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent, then the query will include the default ORDER BY logic from AccountModelImpl
.
userId
- the user IDstart
- the lower bound of the range of accountsend
- the upper bound of the range of accounts (not inclusive)java.util.List<Account> findByUserId(long userId, int start, int end, OrderByComparator<Account> orderByComparator)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil#ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent, then the query will include the default ORDER BY logic from AccountModelImpl
.
userId
- the user IDstart
- the lower bound of the range of accountsend
- the upper bound of the range of accounts (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)java.util.List<Account> findByUserId(long userId, int start, int end, OrderByComparator<Account> orderByComparator, boolean useFinderCache)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil#ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent, then the query will include the default ORDER BY logic from AccountModelImpl
.
userId
- the user IDstart
- the lower bound of the range of accountsend
- the upper bound of the range of accounts (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)useFinderCache
- whether to use the finder cacheAccount findByUserId_First(long userId, OrderByComparator<Account> orderByComparator) throws NoSuchAccountException
userId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchAccountException
- if a matching account could not be foundAccount fetchByUserId_First(long userId, OrderByComparator<Account> orderByComparator)
userId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching account could not be foundAccount findByUserId_Last(long userId, OrderByComparator<Account> orderByComparator) throws NoSuchAccountException
userId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchAccountException
- if a matching account could not be foundAccount fetchByUserId_Last(long userId, OrderByComparator<Account> orderByComparator)
userId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching account could not be foundAccount[] findByUserId_PrevAndNext(long accountId, long userId, OrderByComparator<Account> orderByComparator) throws NoSuchAccountException
accountId
- the primary key of the current accountuserId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchAccountException
- if a account with the primary key could not be foundvoid removeByUserId(long userId)
userId
- the user IDint countByUserId(long userId)
userId
- the user IDAccount findByU_A(long userId, java.lang.String address) throws NoSuchAccountException
NoSuchAccountException
if it could not be found.userId
- the user IDaddress
- the addressNoSuchAccountException
- if a matching account could not be foundAccount fetchByU_A(long userId, java.lang.String address)
null
if it could not be found. Uses the finder cache.userId
- the user IDaddress
- the addressnull
if a matching account could not be foundAccount fetchByU_A(long userId, java.lang.String address, boolean useFinderCache)
null
if it could not be found, optionally using the finder cache.userId
- the user IDaddress
- the addressuseFinderCache
- whether to use the finder cachenull
if a matching account could not be foundAccount removeByU_A(long userId, java.lang.String address) throws NoSuchAccountException
userId
- the user IDaddress
- the addressNoSuchAccountException
int countByU_A(long userId, java.lang.String address)
userId
- the user IDaddress
- the addressvoid cacheResult(Account account)
account
- the accountvoid cacheResult(java.util.List<Account> accounts)
accounts
- the accountsAccount create(long accountId)
accountId
- the primary key for the new accountAccount remove(long accountId) throws NoSuchAccountException
accountId
- the primary key of the accountNoSuchAccountException
- if a account with the primary key could not be foundAccount findByPrimaryKey(long accountId) throws NoSuchAccountException
NoSuchAccountException
if it could not be found.accountId
- the primary key of the accountNoSuchAccountException
- if a account with the primary key could not be foundAccount fetchByPrimaryKey(long accountId)
null
if it could not be found.accountId
- the primary key of the accountnull
if a account with the primary key could not be foundjava.util.List<Account> findAll()
java.util.List<Account> findAll(int start, int end)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil#ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent, then the query will include the default ORDER BY logic from AccountModelImpl
.
start
- the lower bound of the range of accountsend
- the upper bound of the range of accounts (not inclusive)java.util.List<Account> findAll(int start, int end, OrderByComparator<Account> orderByComparator)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil#ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent, then the query will include the default ORDER BY logic from AccountModelImpl
.
start
- the lower bound of the range of accountsend
- the upper bound of the range of accounts (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)java.util.List<Account> findAll(int start, int end, OrderByComparator<Account> orderByComparator, boolean useFinderCache)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil#ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent, then the query will include the default ORDER BY logic from AccountModelImpl
.
start
- the lower bound of the range of accountsend
- the upper bound of the range of accounts (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)useFinderCache
- whether to use the finder cachevoid removeAll()
int countAll()
java.util.Set<java.lang.String> getBadColumnNames()
getBadColumnNames
in interface BasePersistence<Account>