Search in sources :

Example 6 with BwCalSuite

use of org.bedework.calfacade.svc.BwCalSuite in project bw-calendar-engine by Bedework.

the class CalSuites method get.

/* (non-Javadoc)
   * @see org.bedework.calsvci.CalSuitesI#get(org.bedework.calfacade.svc.BwAdminGroup)
   */
@Override
public BwCalSuiteWrapper get(final BwAdminGroup group) throws CalFacadeException {
    BwCalSuite cs = getCal().get(group);
    if (cs == null) {
        return null;
    }
    checkCollections(cs);
    return wrap(cs, false);
}
Also used : BwCalSuite(org.bedework.calfacade.svc.BwCalSuite)

Example 7 with BwCalSuite

use of org.bedework.calfacade.svc.BwCalSuite in project bw-calendar-engine by Bedework.

the class CalSuites method get.

/* (non-Javadoc)
   * @see org.bedework.calsvci.CalSuitesI#get(java.lang.String)
   */
@Override
public BwCalSuiteWrapper get(final String name) throws CalFacadeException {
    BwCalSuite cs = getCal().getCalSuite(name);
    if (cs == null) {
        return null;
    }
    checkCollections(cs);
    return wrap(cs, false);
}
Also used : BwCalSuite(org.bedework.calfacade.svc.BwCalSuite)

Example 8 with BwCalSuite

use of org.bedework.calfacade.svc.BwCalSuite in project bw-calendar-engine by Bedework.

the class CalSuites method update.

@Override
public void update(final BwCalSuiteWrapper csw, final String adminGroupName, final String rootCollectionPath, final String submissionsPath) throws CalFacadeException {
    BwCalSuite cs = csw.fetchEntity();
    if (adminGroupName != null) {
        validateGroup(cs, adminGroupName);
    }
    setRootCol(cs, rootCollectionPath);
    setSubmissionsCol(cs, submissionsPath);
    getCal().saveOrUpdate(cs);
}
Also used : BwCalSuite(org.bedework.calfacade.svc.BwCalSuite)

Example 9 with BwCalSuite

use of org.bedework.calfacade.svc.BwCalSuite in project bw-calendar-engine by Bedework.

the class CalSuites method getAll.

/* (non-Javadoc)
   * @see org.bedework.calsvci.CalSuitesI#getAll()
   */
@Override
public Collection<BwCalSuite> getAll() throws CalFacadeException {
    Collection<BwCalSuite> css = getCal().getAllCalSuites();
    TreeSet<BwCalSuite> retCss = new TreeSet<BwCalSuite>();
    for (BwCalSuite cs : css) {
        checkCollections(cs);
        BwCalSuite w = wrap(cs, true);
        if (w != null) {
            retCss.add(w);
        }
    }
    return retCss;
}
Also used : BwCalSuite(org.bedework.calfacade.svc.BwCalSuite) TreeSet(java.util.TreeSet)

Example 10 with BwCalSuite

use of org.bedework.calfacade.svc.BwCalSuite in project bw-calendar-engine by Bedework.

the class BwCalSuiteWrapper method clone.

/* ====================================================================
   *                   Convenience methods
   * ==================================================================== */
/* ====================================================================
   *                   Object methods
   * ==================================================================== */
@Override
public Object clone() {
    final BwCalSuite cs = (BwCalSuite) entity.clone();
    final BwCalSuiteWrapper csw = new BwCalSuiteWrapper(cs, getCurrentAccess());
    csw.setResourcesHome(getResourcesHome());
    return csw;
}
Also used : BwCalSuite(org.bedework.calfacade.svc.BwCalSuite)

Aggregations

BwCalSuite (org.bedework.calfacade.svc.BwCalSuite)11 HibSession (org.bedework.calcorei.HibSession)2 BwPrincipal (org.bedework.calfacade.BwPrincipal)2 CalFacadeException (org.bedework.calfacade.exc.CalFacadeException)2 TreeSet (java.util.TreeSet)1 PrivilegeSet (org.bedework.access.PrivilegeSet)1 BwPrincipalInfo (org.bedework.calfacade.BwPrincipalInfo)1 BwString (org.bedework.calfacade.BwString)1 Directories (org.bedework.calfacade.ifs.Directories)1 BwAdminGroup (org.bedework.calfacade.svc.BwAdminGroup)1 BwPreferences (org.bedework.calfacade.svc.BwPreferences)1 BwCalSuiteWrapper (org.bedework.calfacade.svc.wrappers.BwCalSuiteWrapper)1