Class DestinationHome
java.lang.Object
ecmwf.web.home.ModelHomeBase
ecmwf.ecpds.master.plugin.http.home.transfer.DestinationHome
public class DestinationHome
extends ecmwf.web.home.ModelHomeBase
The Class DestinationHome.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic final intcountByUser(ecmwf.web.model.users.User user, String search, String fromToAliases, String status, String type, String filter) Count by user.static final Destinationcreate()Creates the.static final Collectionfind(ecmwf.web.model.ModelSearch search) Find.static final Collection<Destination> Find aliased from.static final Collection<Destination> Find aliases.static final Collection<Alias> Find alias list.static final Collection<Destination> findAll()Find all.static final Collection<ecmwf.web.util.bean.Pair> Find all names and comments.static final Collection<Destination> Find all showing in monitor.static final Collection<Destination> Find associated to incoming policy.static final Collection<Destination> Find associated to incoming user.static final Collection<Destination> findByCountry(Country country) Find by country.static final Collection<Destination> findByHost(Host host) Find by host.static final DestinationfindByPrimaryKey(String key) Find by primary key.static final Collection<Destination> findByUser(ecmwf.web.model.users.User user, String search, String fromToAliases, boolean asc, String status, String type, String filter) Find by user.static final Collection<Destination> findByUser(ecmwf.web.model.users.User user, String search, String fromToAliases, int orderColumn, boolean ascending, int start, int length, String status, String type, String filter) Find by user with server-side pagination and sort.static final Collection<ChangeLog> Find change log list.Returns the set of destination names that have at least one active proxy host assigned.static final Collection<Traffic> Find traffic list.Gets the destination counts per host in a single GROUP BY query on the ASSOCIATION table.static final ecmwf.web.model.ModelSearchGets the default search.Gets a map of host name to sorted list of destination names in a single query.Methods inherited from class ecmwf.web.home.ModelHomeBase
getDefaultSearch
-
Constructor Details
-
DestinationHome
public DestinationHome()
-
-
Method Details
-
create
Creates the.- Returns:
- the destination
- Throws:
TransferException- the transfer exception
-
findByPrimaryKey
Find by primary key.- Parameters:
key- the key- Returns:
- the destination
- Throws:
TransferException- the transfer exception
-
findAssociatedToIncomingUser
public static final Collection<Destination> findAssociatedToIncomingUser(IncomingUser u) throws TransferException Find associated to incoming user.- Parameters:
u- the u- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findAssociatedToIncomingPolicy
public static final Collection<Destination> findAssociatedToIncomingPolicy(IncomingPolicy p) throws TransferException Find associated to incoming policy.- Parameters:
p- the p- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findByCountry
Find by country.- Parameters:
country- the country- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findByHost
Find by host.- Parameters:
host- the host- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findByUser
public static final Collection<Destination> findByUser(ecmwf.web.model.users.User user, String search, String fromToAliases, boolean asc, String status, String type, String filter) throws TransferException Find by user.- Parameters:
user- the usersearch- the searchfromToAliases- the from to aliasesasc- the ascstatus- the statustype- the typefilter- the filter- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findByUser
public static final Collection<Destination> findByUser(ecmwf.web.model.users.User user, String search, String fromToAliases, int orderColumn, boolean ascending, int start, int length, String status, String type, String filter) throws TransferException Find by user with server-side pagination and sort.- Parameters:
user- the usersearch- the searchfromToAliases- the from to aliasesorderColumn- the DataTables column index to sort byascending- true for ascending sortstart- the zero-based row offset (-1 for no limit)length- the maximum number of rows (-1 for no limit)status- the statustype- the typefilter- the filter- Returns:
- the collection (just the requested page)
- Throws:
TransferException- the transfer exception
-
countByUser
public static final int countByUser(ecmwf.web.model.users.User user, String search, String fromToAliases, String status, String type, String filter) throws TransferException Count by user.- Parameters:
user- the usersearch- the searchfromToAliases- the from to aliasesstatus- the statustype- the typefilter- the filter- Returns:
- the total count of matching destinations
- Throws:
TransferException- the transfer exception
-
findNamesWithProxyHosts
Returns the set of destination names that have at least one active proxy host assigned. This is a single query covering all destinations, suitable for use in list views without N+1 overhead.- Returns:
- the set of destination names with proxy hosts
- Throws:
TransferException- the transfer exception
-
findAliasList
Find alias list.- Parameters:
d- the d- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findAliases
Find aliases.- Parameters:
d- the d- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findTrafficList
Find traffic list.- Parameters:
d- the d- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findChangeLogList
Find change log list.- Parameters:
d- the d- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findAliasedFrom
Find aliased from.- Parameters:
d- the d- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findAll
Find all.- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findAllNamesAndComments
public static final Collection<ecmwf.web.util.bean.Pair> findAllNamesAndComments() throws TransferExceptionFind all names and comments.- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
findAllShowingInMonitor
Find all showing in monitor.- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
find
Find.- Parameters:
search- the search- Returns:
- the collection
- Throws:
TransferException- the transfer exception
-
getDefaultSearch
Gets the default search.- Parameters:
s- the s- Returns:
- the default search
-
getCountsByHost
Gets the destination counts per host in a single GROUP BY query on the ASSOCIATION table.- Returns:
- map of host name → destination count
- Throws:
TransferException- the transfer exception
-
getNamesByHost
Gets a map of host name to sorted list of destination names in a single query.- Returns:
- map of host name → sorted list of destination names
- Throws:
TransferException- the transfer exception
-