当前位置: 首页>>代码示例>>Java>>正文


Java UserDefinedAssessmentTypeCollection.get方法代码示例

本文整理汇总了Java中ims.core.vo.lookups.UserDefinedAssessmentTypeCollection.get方法的典型用法代码示例。如果您正苦于以下问题:Java UserDefinedAssessmentTypeCollection.get方法的具体用法?Java UserDefinedAssessmentTypeCollection.get怎么用?Java UserDefinedAssessmentTypeCollection.get使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ims.core.vo.lookups.UserDefinedAssessmentTypeCollection的用法示例。


在下文中一共展示了UserDefinedAssessmentTypeCollection.get方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getUserDefinedTypes

import ims.core.vo.lookups.UserDefinedAssessmentTypeCollection; //导入方法依赖的package包/类
private UserDefinedAssessmentTypeCollection getUserDefinedTypes(UserDefinedAssessmentType type)
{
	UserDefinedAssessmentTypeCollection assTypeColl = new UserDefinedAssessmentTypeCollection();
	if(type != null)
	{
		assTypeColl.add(type);
		
		UserDefinedAssessmentTypeCollection udfColl = LookupHelper.getUserDefinedAssessmentType(domain.getLookupService());
		
		for (int i = 0; i < udfColl.size(); i++)
		{
			UserDefinedAssessmentType lkpType = udfColl.get(i);
			if(type.equals(lkpType))
			{
				//Add the children (if any) to the collection
				for (int j = 0; lkpType.getChildInstances() != null && j < lkpType.getChildInstances().size(); j++)
				{
					assTypeColl.add((UserDefinedAssessmentType)lkpType.getChildInstances().get(j));
				}
			}
		}
	}

	return assTypeColl;
}
 
开发者ID:oopcell,项目名称:AvoinApotti,代码行数:26,代码来源:Logic.java

示例2: populateLookups

import ims.core.vo.lookups.UserDefinedAssessmentTypeCollection; //导入方法依赖的package包/类
private void populateLookups()
{
	form.cmbComponent().clear();
	//WDEV-1692 - Display first level one lookups
	UserDefinedAssessmentTypeCollection lookupColl = LookupHelper.getUserDefinedAssessmentType(domain.getLookupService());
	LookupInstVo[] lookupParents = lookupColl.getRoots();
	for (int i = 0; lookupColl != null && i < lookupColl.size(); i++)
	{
		UserDefinedAssessmentType assessmentType = lookupColl.get(i);
		if (lookupHasARootParent(lookupParents, assessmentType))
		{
			form.cmbComponent().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor());
		}
	}
}
 
开发者ID:oopcell,项目名称:AvoinApotti,代码行数:16,代码来源:Logic.java

示例3: getUserDefinedTypes

import ims.core.vo.lookups.UserDefinedAssessmentTypeCollection; //导入方法依赖的package包/类
private UserDefinedAssessmentTypeCollection getUserDefinedTypes(UserDefinedAssessmentType type, UserDefinedAssessmentType excludedType)
{
	UserDefinedAssessmentTypeCollection assTypeColl = new UserDefinedAssessmentTypeCollection();
	if(type != null)
	{
		assTypeColl.add(type);
		
		UserDefinedAssessmentTypeCollection udfColl = LookupHelper.getUserDefinedAssessmentType(domain.getLookupService());
		
		for (int i = 0; i < udfColl.size(); i++)
		{
			UserDefinedAssessmentType lkpType = udfColl.get(i);
				
			if(type.equals(lkpType))
			{
				//Add the children (if any) to the collection
				for (int j = 0; lkpType.getChildInstances() != null && j < lkpType.getChildInstances().size(); j++)
				{
					UserDefinedAssessmentType userDefinedAssessmentType = (UserDefinedAssessmentType)lkpType.getChildInstances().get(j);
					if(excludedType != null && excludedType.equals(userDefinedAssessmentType))
						continue;
					assTypeColl.add(userDefinedAssessmentType);
				}
			}
		}
	}

	return assTypeColl;
}
 
开发者ID:oopcell,项目名称:AvoinApotti,代码行数:30,代码来源:Logic.java

示例4: listUserAssessments

import ims.core.vo.lookups.UserDefinedAssessmentTypeCollection; //导入方法依赖的package包/类
public ims.assessment.vo.UserAssessmentLiteVoCollection listUserAssessments(UserDefinedAssessmentTypeCollection assessmentTypes)
{
	if (assessmentTypes == null || assessmentTypes.size() == 0)
		throw new CodingRuntimeException("Cannot list UserAssessment for null assessmentTypes");

	DomainFactory factory = getDomainFactory();
	StringBuffer hql = new StringBuffer("from UserAssessment u ");
	ArrayList markers = new ArrayList();
	ArrayList values = new ArrayList();
	String orStr = " where ";

	// AssessmentType
	for (int i = 0; i < assessmentTypes.size(); i++)
	{
		UserDefinedAssessmentType type = assessmentTypes.get(i);
		if (type != null)
		{
			String marker = "assType" + i;
			hql.append(orStr + " u.assessmentType =:" + marker);
			markers.add(marker);
			values.add(getDomLookup(type));
			orStr = " or ";
		}
	}

	List list = factory.find(hql.toString(), markers, values);

	return UserAssessmentLiteVoAssembler.createUserAssessmentLiteVoCollectionFromUserAssessment(list).sort(SortOrder.DESCENDING);
}
 
开发者ID:oopcell,项目名称:AvoinApotti,代码行数:30,代码来源:DPPGroupingsConfigImpl.java

示例5: listGraphicAssesssments

import ims.core.vo.lookups.UserDefinedAssessmentTypeCollection; //导入方法依赖的package包/类
private GraphicAssessmentShortVoCollection listGraphicAssesssments(String name, ims.core.vo.lookups.PreActiveActiveInactiveStatus status, UserDefinedAssessmentTypeCollection types)
{
	DomainFactory factory = getDomainFactory();
	StringBuffer hql = new StringBuffer("from GraphicAssessment ga ");
	ArrayList names = new ArrayList();
	ArrayList values = new ArrayList();
	String clause = " where ";

	if (name != null)
	{
		hql.append(clause);
		hql.append(" upper(ga.name) like :name");
		names.add("name");
		values.add(name.toUpperCase());
		clause = " and ";
	}
	if (status != null)
	{
		hql.append(clause);
		hql.append(" ga.activeStatus = :status");
		names.add("status");
		values.add(getDomLookup(status));
		clause = " and ";
	}

	if (types != null)
	{
		int size = types.size();
		for (int i = 0; i < size; i++)
		{
			UserDefinedAssessmentType assType = types.get(i);
			// Check if " where " clause was added previously
			hql.append(clause);
			if (i == 0)
				hql.append(" (");

			hql.append("ga.assessmentType.id =:assessmentType" + Integer.toString(i));
			names.add("assessmentType" + i);
			values.add(new Integer(assType.getId()));

			if (i == (size - 1))
				hql.append(")");

			clause = " or ";
		}
		
		clause = " and ";
	}

	List list = factory.find(hql.toString(), names, values);

	return GraphicAssessmentShortVoAssembler.createGraphicAssessmentShortVoCollectionFromGraphicAssessment(list);
}
 
开发者ID:oopcell,项目名称:AvoinApotti,代码行数:54,代码来源:GraphicAssessmentsImpl.java

示例6: listAssessments

import ims.core.vo.lookups.UserDefinedAssessmentTypeCollection; //导入方法依赖的package包/类
public UserAssessmentShortVoCollection listAssessments(String name, ims.core.vo.lookups.UserAssessmentCategory category, UserDefinedAssessmentTypeCollection assessmentTypeColl, ims.core.vo.lookups.PreActiveActiveInactiveStatus status)
{
	DomainFactory factory = getDomainFactory();
	StringBuffer hql = new StringBuffer(" ");
	String query = "from UserAssessment u ";
	ArrayList markers = new ArrayList();
	ArrayList values = new ArrayList();
	String andStr = " ";

	if (name != null && name.length() > 0)
	{
		hql.append(andStr + " upper(u.name) like :name");
		markers.add("name");
		values.add(name.toUpperCase());
		andStr = " and ";

	}
	if (category != null)
	{
		hql.append(andStr + " u.category.id =:category");
		markers.add("category");
		values.add(new Integer(category.getId()));
		andStr = " and ";
	}

	if (status != null)
	{
		hql.append(andStr + " u.activeStatus =:status");
		markers.add("status");
		values.add(getDomLookup(status));
		andStr = " and ";
	}

	if (assessmentTypeColl != null)
	{
		int size = assessmentTypeColl.size();
		for (int i = 0; i < size; i++)
		{
			UserDefinedAssessmentType assType = assessmentTypeColl.get(i);
			hql.append(andStr);
			if (i == 0)
				hql.append(" (");
			hql.append(" u.assessmentType.id =:assessmentType" + Integer.toString(i));
			markers.add("assessmentType" + i);
			values.add(new Integer(assType.getId()));
			andStr = " or ";

			if (i == (size - 1))
				hql.append(")");	
		}
	}

	if (markers.size() > 0)
		query += " where ";

	query += hql.toString();

	List list = factory.find(query, markers, values);

	return UserAssessmentShortVoAssembler.createUserAssessmentShortVoCollectionFromUserAssessment(list).sort();
}
 
开发者ID:oopcell,项目名称:AvoinApotti,代码行数:62,代码来源:UserAssessmentsImpl.java


注:本文中的ims.core.vo.lookups.UserDefinedAssessmentTypeCollection.get方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。