Examples of CategoryManager


Examples of evolaris.mgbl.gs.business.CategoryManager

    super.tearDown();
    HibernateSessions.finishTransaction(session,this.getClass());
  }

  public void testGetCriterias() {
    CategoryManager categoryManager = new CategoryManager(Locale.ENGLISH,session);
    Category[] categories = categoryManager.getSortedCategories();
    for (int i = 0; i < categories.length; i++) {
      CriteriaGroup[] criteriaGroups = categoryManager.getSortedGroups(categories[i]);
      for (int j = 0; j < criteriaGroups.length; j++) {
        Criteria[] criteria = criteriaManager.getSortedCriterias(criteriaGroups[j]);
        if (criteria.length >= 2){
          assertTrue("criteria not sorted",criteria[0].getSortorder() <= criteria[1].getSortorder());
          return;
View Full Code Here

Examples of evolaris.mgbl.gs.business.CategoryManager

   */
  @Override
  protected void setUp() throws Exception {
    super.setUp();
    session = HibernateSessions.startTransaction(this.getClass());
    categoryManager = new CategoryManager(Locale.ENGLISH,session);
  }
View Full Code Here

Examples of evolaris.mgbl.gs.business.CategoryManager

   */
  private ApplicationType[] findAppropriateApplications(HttpServletRequest req, Map<String, String[][]> criteriasInGroupsAndCategories) {
    ApplicationManager applicationManager = new ApplicationManager(req.getLocale(),session);
    ApplicationType[] applications = applicationManager.getApplications();
    float[] applicationWeights = new float[applications.length];
    CategoryManager categoryManager = new CategoryManager(req.getLocale(),session);
    CriteriaManager criteriaManager = new CriteriaManager(req.getLocale(),session);
    Category[] categories = categoryManager.getSortedCategories();
    try {
     
      // evaluate user input for all categories (input pages)
     
      for (Category category : categories) {
        String categoryname = category.getCategoryname();
        String[][] criteriasInCategory = criteriasInGroupsAndCategories.get(categoryname);

        if (criteriasInCategory != null) {  // input page "touched"
          CriteriaGroup[] groups = categoryManager.getSortedGroups(category);
         
          // evaluate user input within the groups of a category
         
          for (int groupX = 0; groupX < groups.length; groupX++) {
            CriteriaGroup group = groups[groupX];
View Full Code Here

Examples of evolaris.mgbl.gs.business.CategoryManager

  /**
   * Prepares request attributes for groups and criteria
   */
  protected String[][][] prepareGroupsAndCriteria(HttpServletRequest req, Category[] categories) {
    CategoryManager categoryManager = new CategoryManager(req.getLocale(),session);
    CriteriaManager criteriaManager = new CriteriaManager(req.getLocale(),session);
 
    String groupnames[][] = new String[categories.length][];
    String formpropertynames[][] = new String[categories.length][];
    String criterianames[][][] = new String[categories.length][][];
    String criteriaDescriptions[][][] = new String[categories.length][][];
   
    for (int c=0; c<categories.length; c++) {
      CriteriaGroup[] groups = categoryManager.getSortedGroups(categories[c]);
      groupnames[c] = new String[groups.length];
      formpropertynames[c] = new String[groups.length];
      criterianames[c] = new String[groups.length][];
      criteriaDescriptions[c] = new String[groups.length][];
      if (groups.length > MAX_NOF_GROUPS){
View Full Code Here

Examples of evolaris.mgbl.gs.business.CategoryManager

  /**
   * Prepares request attributes for category tabs
   */
  protected Category[] prepareCategories(HttpServletRequest req) {
    CategoryManager categoryManager = new CategoryManager(req.getLocale(),session);
    Category[] categories = categoryManager.getSortedCategories();
    if (categories.length == 0){
      throw new ConfigurationException("No categories configured");
    }
    if (categories.length > MAX_NOF_CATEGORIES) {
      throw new ConfigurationException("Not more than "+MAX_NOF_CATEGORIES+" must be used.");
View Full Code Here

Examples of org.drools.guvnor.client.admin.CategoryManager

        int id = Integer.parseInt(self.getAttribute("id"));
        switch (id) {
        case 0:
          if (!centertabbedPanel.showIfOpen("catman")) //NON-NLS
            centertabbedPanel.addTab(constants.CategoryManager(), true,
                new CategoryManager(), "catman"); //NON-NLS
          break;
        case 1:
          if (!centertabbedPanel.showIfOpen("archman"))  //NON-NLS
            centertabbedPanel.addTab(constants.ArchivedManager(), true,
                new ArchivedAssetManager(centertabbedPanel),
View Full Code Here

Examples of org.drools.guvnor.client.admin.CategoryManager

        int id = Integer.parseInt(self.getAttribute("id"));
        switch (id) {
        case 0:
          if (!centertabbedPanel.showIfOpen("catman")) //NON-NLS
            centertabbedPanel.addTab(constants.CategoryManager(), true,
                new CategoryManager(), "catman"); //NON-NLS
          break;
        case 1:
          if (!centertabbedPanel.showIfOpen("archman"))  //NON-NLS
            centertabbedPanel.addTab(constants.ArchivedManager(), true,
                new ArchivedAssetManager(centertabbedPanel),
View Full Code Here

Examples of org.drools.guvnor.client.admin.CategoryManager

                                            final EventBus eventBus) {

        switch ( id ) {
            case 0 :
                tabbedPanel.add( constants.CategoryManager(),
                                 new CategoryManager() );
                break;
            case 1 :
                tabbedPanel.add( constants.ArchivedManager(),
                                 new ArchivedAssetManager( clientFactory,
                                                           eventBus ) );
View Full Code Here

Examples of org.drools.guvnor.client.admin.CategoryManager

    public void openAdministrationSelection(AcceptItem tabbedPanel, int id) {

        switch (id) {
            case 0:
                tabbedPanel.add(constants.CategoryManager(),
                        new CategoryManager());
                break;
            case 1:
                tabbedPanel.add(constants.ArchivedManager(),
                        new ArchivedAssetManager(clientFactory));
                break;
View Full Code Here

Examples of org.drools.guvnor.client.admin.CategoryManager

        switch ( id ) {
            case 0 :
                if ( !explorerViewCenterPanel.showIfOpen( CATMAN ) ) {
                    explorerViewCenterPanel.addTab( constants.CategoryManager(),
                                                    new CategoryManager(),
                                                    CATMAN );
                }
                break;
            case 1 :
                if ( !explorerViewCenterPanel.showIfOpen( ARCHMAN ) ) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.