org.infoglue.deliver.controllers.kernel.impl.simple
Class LanguageDeliveryController

java.lang.Object
  extended by org.infoglue.deliver.controllers.kernel.impl.simple.BaseDeliveryController
      extended by org.infoglue.deliver.controllers.kernel.impl.simple.LanguageDeliveryController

public class LanguageDeliveryController
extends BaseDeliveryController


Method Summary
 java.util.List getAvailableLanguages(org.exolab.castor.jdo.Database db, java.lang.Integer siteNodeId)
          This method returns the languages assigned to a respository.
 java.util.List getAvailableLanguagesForRepository(org.exolab.castor.jdo.Database db, java.lang.Integer repositoryId)
          This method returns all languages for a certain repository.
 boolean getIsValidLanguage(org.exolab.castor.jdo.Database db, NodeDeliveryController ndc, SiteNode siteNode, java.lang.Integer languageId)
           
static LanguageDeliveryController getLanguageDeliveryController()
          Factory method
 LanguageVO getLanguageIfRepositorySupportsIt(org.exolab.castor.jdo.Database db, java.lang.String languageCodes, java.lang.Integer siteNodeId)
          This method returns language with the languageCode sent in if it is allowed/supported in the current repository.
 LanguageVO getLanguageIfSiteNodeSupportsIt(org.exolab.castor.jdo.Database db, java.lang.Integer languageId, java.lang.Integer siteNodeId)
          This method returns language with the languageCode sent in if it is allowed/supported in the current repository.
 LanguageVO getLanguageIfSiteNodeSupportsIt(org.exolab.castor.jdo.Database db, java.lang.String languageCodes, java.lang.Integer siteNodeId, InfoGluePrincipal principal)
          This method returns language with the languageCode sent in if it is allowed/supported in the current repository.
 java.util.List getLanguagesForSiteNode(org.exolab.castor.jdo.Database db, java.lang.Integer siteNodeId, InfoGluePrincipal principal)
          This method returns all languages available for a site node.
 LanguageVO getLanguageWithCode(org.exolab.castor.jdo.Database db, java.lang.String languageCode)
          This method returns language with the languageCode sent in.
 LanguageVO getLanguageVO(org.exolab.castor.jdo.Database db, java.lang.Integer languageId)
          This method return a LanguageVO
 java.util.Locale getLocaleWithCode(java.lang.String languageCode)
          This method returns language with the languageCode sent in.
 java.util.Locale getLocaleWithId(org.exolab.castor.jdo.Database db, java.lang.Integer languageId)
          This method returns language with the languageCode sent in.
 LanguageVO getMasterLanguage(org.exolab.castor.jdo.Database db, java.lang.String repositoryName)
          This method returns the master language.
 LanguageVO getMasterLanguageForRepository(org.exolab.castor.jdo.Database db, java.lang.Integer repositoryId)
          This method returns the master language.
 LanguageVO getMasterLanguageForRepository(java.lang.Integer repositoryId, org.exolab.castor.jdo.Database db)
          This method returns the master language.
 LanguageVO getMasterLanguageForSiteNode(org.exolab.castor.jdo.Database db, java.lang.Integer siteNodeId)
          This method returns the master language.
 
Methods inherited from class org.infoglue.deliver.controllers.kernel.impl.simple.BaseDeliveryController
beginTransaction, closeDatabase, closeTransaction, commitTransaction, createQuery, executeQuery, executeQuery, getAllVOObjects, getAllVOObjects, getObjectWithId, getVOWithId, rollbackTransaction, toVOList
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getLanguageDeliveryController

public static LanguageDeliveryController getLanguageDeliveryController()
Factory method


getLanguageVO

public LanguageVO getLanguageVO(org.exolab.castor.jdo.Database db,
                                java.lang.Integer languageId)
                         throws SystemException,
                                java.lang.Exception
This method return a LanguageVO

Throws:
SystemException
java.lang.Exception

getAvailableLanguagesForRepository

public java.util.List getAvailableLanguagesForRepository(org.exolab.castor.jdo.Database db,
                                                         java.lang.Integer repositoryId)
                                                  throws SystemException,
                                                         java.lang.Exception
This method returns all languages for a certain repository.

Parameters:
repositoryId -
Returns:
Throws:
SystemException
java.lang.Exception

getAvailableLanguages

public java.util.List getAvailableLanguages(org.exolab.castor.jdo.Database db,
                                            java.lang.Integer siteNodeId)
                                     throws SystemException,
                                            java.lang.Exception
This method returns the languages assigned to a respository.

Throws:
SystemException
java.lang.Exception

getMasterLanguage

public LanguageVO getMasterLanguage(org.exolab.castor.jdo.Database db,
                                    java.lang.String repositoryName)
                             throws SystemException,
                                    java.lang.Exception
This method returns the master language. todo - add attribute on repositoryLanguage to be able to sort them... and then fetch the first

Throws:
SystemException
java.lang.Exception

getMasterLanguageForRepository

public LanguageVO getMasterLanguageForRepository(org.exolab.castor.jdo.Database db,
                                                 java.lang.Integer repositoryId)
                                          throws SystemException,
                                                 java.lang.Exception
This method returns the master language. todo - add attribute on repositoryLanguage to be able to sort them... and then fetch the first

Throws:
SystemException
java.lang.Exception

getMasterLanguageForRepository

public LanguageVO getMasterLanguageForRepository(java.lang.Integer repositoryId,
                                                 org.exolab.castor.jdo.Database db)
                                          throws SystemException,
                                                 java.lang.Exception
This method returns the master language. todo - add attribute on repositoryLanguage to be able to sort them... and then fetch the first

Throws:
SystemException
java.lang.Exception

getMasterLanguageForSiteNode

public LanguageVO getMasterLanguageForSiteNode(org.exolab.castor.jdo.Database db,
                                               java.lang.Integer siteNodeId)
                                        throws SystemException,
                                               java.lang.Exception
This method returns the master language. todo - add attribute on repositoryLanguage to be able to sort them... and then fetch the first

Throws:
SystemException
java.lang.Exception

getLocaleWithId

public java.util.Locale getLocaleWithId(org.exolab.castor.jdo.Database db,
                                        java.lang.Integer languageId)
This method returns language with the languageCode sent in.


getLocaleWithCode

public java.util.Locale getLocaleWithCode(java.lang.String languageCode)
This method returns language with the languageCode sent in.


getLanguageWithCode

public LanguageVO getLanguageWithCode(org.exolab.castor.jdo.Database db,
                                      java.lang.String languageCode)
                               throws SystemException,
                                      java.lang.Exception
This method returns language with the languageCode sent in.

Throws:
SystemException
java.lang.Exception

getLanguageIfRepositorySupportsIt

public LanguageVO getLanguageIfRepositorySupportsIt(org.exolab.castor.jdo.Database db,
                                                    java.lang.String languageCodes,
                                                    java.lang.Integer siteNodeId)
                                             throws SystemException,
                                                    java.lang.Exception
This method returns language with the languageCode sent in if it is allowed/supported in the current repository.

Throws:
SystemException
java.lang.Exception

getLanguageIfSiteNodeSupportsIt

public LanguageVO getLanguageIfSiteNodeSupportsIt(org.exolab.castor.jdo.Database db,
                                                  java.lang.String languageCodes,
                                                  java.lang.Integer siteNodeId,
                                                  InfoGluePrincipal principal)
                                           throws SystemException,
                                                  java.lang.Exception
This method returns language with the languageCode sent in if it is allowed/supported in the current repository.

Throws:
SystemException
java.lang.Exception

getLanguageIfSiteNodeSupportsIt

public LanguageVO getLanguageIfSiteNodeSupportsIt(org.exolab.castor.jdo.Database db,
                                                  java.lang.Integer languageId,
                                                  java.lang.Integer siteNodeId)
                                           throws SystemException,
                                                  java.lang.Exception
This method returns language with the languageCode sent in if it is allowed/supported in the current repository.

Throws:
SystemException
java.lang.Exception

getLanguagesForSiteNode

public java.util.List getLanguagesForSiteNode(org.exolab.castor.jdo.Database db,
                                              java.lang.Integer siteNodeId,
                                              InfoGluePrincipal principal)
                                       throws SystemException,
                                              java.lang.Exception
This method returns all languages available for a site node.

Throws:
SystemException
java.lang.Exception

getIsValidLanguage

public boolean getIsValidLanguage(org.exolab.castor.jdo.Database db,
                                  NodeDeliveryController ndc,
                                  SiteNode siteNode,
                                  java.lang.Integer languageId)
                           throws java.lang.Exception
Throws:
java.lang.Exception


Copyright © 2005 InfoGlue.org All Rights Reserved.