本文整理汇总了Java中org.kuali.rice.core.api.exception.RiceRemoteServiceConnectionException类的典型用法代码示例。如果您正苦于以下问题:Java RiceRemoteServiceConnectionException类的具体用法?Java RiceRemoteServiceConnectionException怎么用?Java RiceRemoteServiceConnectionException使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
RiceRemoteServiceConnectionException类属于org.kuali.rice.core.api.exception包,在下文中一共展示了RiceRemoteServiceConnectionException类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getCustomActionListAttribute
import org.kuali.rice.core.api.exception.RiceRemoteServiceConnectionException; //导入依赖的package包/类
public CustomActionListAttribute getCustomActionListAttribute() throws ResourceUnavailableException {
CustomActionListAttribute result = null;
RuleAttribute customActionListRuleAttribute = getCustomActionListRuleAttribute();
if (customActionListRuleAttribute != null) {
try {
ExtensionDefinition extensionDefinition =
KewApiServiceLocator.getExtensionRepositoryService().getExtensionById(customActionListRuleAttribute.getId());
if (extensionDefinition != null) {
result = ExtensionUtils.loadExtension(extensionDefinition, customActionListRuleAttribute.getApplicationId());
} else {
LOG.warn("Could not load ExtensionDefinition for " + customActionListRuleAttribute);
}
} catch (RiceRemoteServiceConnectionException e) {
LOG.warn("Unable to connect to load custom action list attribute for " + customActionListRuleAttribute, e);
}
}
return result;
}
示例2: getInInterceptors
import org.kuali.rice.core.api.exception.RiceRemoteServiceConnectionException; //导入依赖的package包/类
public static List<Interceptor<? extends Message>> getInInterceptors() {
try {
return (List<Interceptor<? extends Message>>) getService(KSBConstants.ServiceNames.BUS_IN_INTERCEPTORS);
}
catch(RiceRemoteServiceConnectionException ex) {
// swallow this exception, means no bus wide interceptors defined
return null;
}
}
示例3: getOutInterceptors
import org.kuali.rice.core.api.exception.RiceRemoteServiceConnectionException; //导入依赖的package包/类
public static List<Interceptor<? extends Message>> getOutInterceptors() {
try {
return (List<Interceptor<? extends Message>>) getService(KSBConstants.ServiceNames.BUS_OUT_INTERCEPTORS);
}
catch(RiceRemoteServiceConnectionException ex) {
// swallow this exception, means no bus wide interceptors defined
return null;
}
}
示例4: getDocumentSearchConfiguration
import org.kuali.rice.core.api.exception.RiceRemoteServiceConnectionException; //导入依赖的package包/类
@Override
public DocumentSearchCriteriaConfiguration getDocumentSearchConfiguration(String documentTypeName,
List<String> searchableAttributeNames) {
if (StringUtils.isBlank(documentTypeName)) {
throw new RiceIllegalArgumentException("documentTypeName was null or blank");
}
if (searchableAttributeNames == null) {
throw new RiceIllegalArgumentException("searchableAttributeNames was null");
}
DocumentSearchCriteriaConfiguration.Builder configBuilder = DocumentSearchCriteriaConfiguration.Builder.create();
if (CollectionUtils.isNotEmpty(searchableAttributeNames)) {
try {
List<AttributeFields> searchAttributeFields = new ArrayList<AttributeFields>();
for (String searchableAttributeName : searchableAttributeNames) {
ExtensionDefinition extensionDefinition = getExtensionRepositoryService().getExtensionByName(searchableAttributeName);
if (extensionDefinition == null) {
throw new RiceIllegalArgumentException("Failed to locate a SearchableAttribute with the given name: " + searchableAttributeName);
}
SearchableAttribute searchableAttribute = loadSearchableAttribute(extensionDefinition);
List<RemotableAttributeField> attributeSearchFields = searchableAttribute.getSearchFields(extensionDefinition, documentTypeName);
if (CollectionUtils.isNotEmpty(attributeSearchFields)) {
searchAttributeFields.add(AttributeFields.create(searchableAttributeName, attributeSearchFields));
}
}
configBuilder.setSearchAttributeFields(searchAttributeFields);
} catch (RiceRemoteServiceConnectionException e) {
LOG.warn("Unable to connect to load searchable attributes for document type: " + documentTypeName, e);
}
}
return configBuilder.build();
}
示例5: validateCriteria
import org.kuali.rice.core.api.exception.RiceRemoteServiceConnectionException; //导入依赖的package包/类
@Override
public List<RemotableAttributeError> validateCriteria(DocumentSearchCriteria documentSearchCriteria,
List<String> searchableAttributeNames) {
if (documentSearchCriteria == null) {
throw new RiceIllegalArgumentException("documentSearchCriteria was null or blank");
}
if (searchableAttributeNames == null) {
throw new RiceIllegalArgumentException("searchableAttributeNames was null");
}
try {
List<RemotableAttributeError> searchFieldErrors = new ArrayList<RemotableAttributeError>();
for (String searchableAttributeName : searchableAttributeNames) {
ExtensionDefinition extensionDefinition = getExtensionRepositoryService().getExtensionByName(searchableAttributeName);
if (extensionDefinition == null) {
throw new RiceIllegalArgumentException("Failed to locate a SearchableAttribute with the given name: " + searchableAttributeName);
}
SearchableAttribute searchableAttribute = loadSearchableAttribute(extensionDefinition);
List<RemotableAttributeError> errors = searchableAttribute.validateDocumentAttributeCriteria(extensionDefinition,
documentSearchCriteria);
if (!CollectionUtils.isEmpty(errors)) {
searchFieldErrors.addAll(errors);
}
}
return Collections.unmodifiableList(searchFieldErrors);
} catch (RiceRemoteServiceConnectionException e) {
LOG.warn("Unable to connect to load searchable attributes for criteria: " + documentSearchCriteria, e);
return Collections.emptyList();
}
}
示例6: loadSearchableAttributes
import org.kuali.rice.core.api.exception.RiceRemoteServiceConnectionException; //导入依赖的package包/类
public List<ExtensionHolder<SearchableAttribute>> loadSearchableAttributes() {
List<DocumentTypeAttributeBo> searchableAttributes = getSearchableAttributes();
List<ExtensionHolder<SearchableAttribute>> loadedAttributes = new ArrayList<ExtensionHolder<SearchableAttribute>>();
for (DocumentTypeAttributeBo documentTypeAttribute : searchableAttributes) {
RuleAttribute ruleAttribute = documentTypeAttribute.getRuleAttribute();
try {
ExtensionDefinition extensionDefinition = KewApiServiceLocator.getExtensionRepositoryService().getExtensionById(ruleAttribute.getId());
SearchableAttribute attributeService = ExtensionUtils.loadExtension(extensionDefinition, getApplicationId());
loadedAttributes.add(new ExtensionHolder<SearchableAttribute>(extensionDefinition, attributeService));
} catch (RiceRemoteServiceConnectionException e) {
LOG.warn("Unable to connect to load searchable attribute for " + ruleAttribute, e);
}
}
return loadedAttributes;
}
示例7: getService
import org.kuali.rice.core.api.exception.RiceRemoteServiceConnectionException; //导入依赖的package包/类
public static <T extends Object> T getService(QName serviceName) {
if (serviceName == null) {
throw new IllegalArgumentException("The service name must be non-null.");
}
LOG.debug("GlobalResourceLoader fetching service " + serviceName);
try {
ResourceLoader resourceLoader = getResourceLoader();
return resourceLoader == null ? null : resourceLoader.<T>getService(serviceName);
} catch (RiceRemoteServiceConnectionException ex) {
LOG.warn(ex.getMessage());
return null;
}
}
示例8: getService
import org.kuali.rice.core.api.exception.RiceRemoteServiceConnectionException; //导入依赖的package包/类
public static <T extends Object> T getService(QName serviceName) {
if (serviceName == null) {
throw new IllegalArgumentException("The service name must be non-null.");
}
LOG.debug("GlobalResourceLoader fetching service " + serviceName);
try {
return getResourceLoader().<T>getService(serviceName);
} catch (RiceRemoteServiceConnectionException ex) {
LOG.warn(ex.getMessage());
return null;
}
}