fr.paris.lutece.plugins.phraseanet.service
Class PhraseanetService

java.lang.Object
  extended by fr.paris.lutece.plugins.phraseanet.service.PhraseanetService

public final class PhraseanetService
extends Object

PhraseanetService


Method Summary
static List<Collection> getColletions(int nDataboxId, Account account)
          Get all collections of databox
static List<Metadata> getDataboxeMetadatas(int nDataboxId, Account account)
          Get metadatas for a given databoxe
static List<Databox> getDataboxes(Account account)
          Get databoxes
static Embed getEmbed(int nDataboxId, int nRecordId, Account account)
          Get embed data of a record
static List<String> getItemsPerPageValues()
          Gets items per page values
static List<String> getMediaTypeValues()
          Get media types values
static Record getRecord(int nDataboxId, int nRecordId, Account account)
          Gets a record
static List<Metadata> getRecordMetadatas(int nDataboxId, int nRecordId, Account account)
          Get metadatas for a given record
static SearchResults search(String strQuery, int nPage, int nPerPage, SearchCriterias criterias, Account account)
          Searc results
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getRecord

public static Record getRecord(int nDataboxId,
                               int nRecordId,
                               Account account)
                        throws PhraseanetApiCallException
Gets a record

Parameters:
nDataboxId - The databox id
nRecordId - The record id
account - the user phraseanet account
Returns:
The record
Throws:
PhraseanetApiCallException - if an error occurs

getDataboxeMetadatas

public static List<Metadata> getDataboxeMetadatas(int nDataboxId,
                                                  Account account)
                                           throws PhraseanetApiCallException
Get metadatas for a given databoxe

Parameters:
nDataboxId - The databox id
account - the user phraseanet account
Returns:
Metadatas
Throws:
PhraseanetApiCallException - if an error occurs

getRecordMetadatas

public static List<Metadata> getRecordMetadatas(int nDataboxId,
                                                int nRecordId,
                                                Account account)
                                         throws PhraseanetApiCallException
Get metadatas for a given record

Parameters:
nDataboxId - The databox id
nRecordId - The record id
account - the user phraseanet account
Returns:
Metadatas
Throws:
PhraseanetApiCallException - if an error occurs

search

public static SearchResults search(String strQuery,
                                   int nPage,
                                   int nPerPage,
                                   SearchCriterias criterias,
                                   Account account)
                            throws PhraseanetApiCallException
Searc results

Parameters:
strQuery - Query terms
nPage - Page number
nPerPage - Number of items per page
criterias - Criterias
account - the user phraseanet account
Returns:
search results
Throws:
PhraseanetApiCallException - if an error occurs

getDataboxes

public static List<Databox> getDataboxes(Account account)
                                  throws PhraseanetApiCallException
Get databoxes

Parameters:
account - the user phraseanet account
Returns:
The lis of databoxes
Throws:
PhraseanetApiCallException - if an error occurs

getColletions

public static List<Collection> getColletions(int nDataboxId,
                                             Account account)
                                      throws PhraseanetApiCallException
Get all collections of databox

Parameters:
nDataboxId - The databox id
account - the user phraseanet account
Returns:
a collection list
Throws:
PhraseanetApiCallException - if an error occurs

getEmbed

public static Embed getEmbed(int nDataboxId,
                             int nRecordId,
                             Account account)
                      throws PhraseanetApiCallException
Get embed data of a record

Parameters:
nDataboxId - The databox id
nRecordId - The record id
account - the user phraseanet account
Returns:
embed data
Throws:
PhraseanetApiCallException - if an error occurs

getItemsPerPageValues

public static List<String> getItemsPerPageValues()
Gets items per page values

Returns:
items per page values

getMediaTypeValues

public static List<String> getMediaTypeValues()
Get media types values

Returns:
media types values


Copyright © 2013 Mairie de Paris. All Rights Reserved.