• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Java Inactivatable类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.kuali.rice.core.api.mo.common.active.Inactivatable的典型用法代码示例。如果您正苦于以下问题:Java Inactivatable类的具体用法?Java Inactivatable怎么用?Java Inactivatable使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



Inactivatable类属于org.kuali.rice.core.api.mo.common.active包,在下文中一共展示了Inactivatable类的18个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: filter

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Iterates through the collection and if the collection line type implements <code>Inactivatable</code>,
 * active indexes are added to the show indexes list
 *
 * {@inheritDoc}
 */
@Override
public List<Integer> filter(View view, Object model, CollectionGroup collectionGroup) {
    // get the collection for this group from the model
    List<Object> modelCollection =
            ObjectPropertyUtils.getPropertyValue(model, collectionGroup.getBindingInfo().getBindingPath());

    // iterate through and add only active indexes
    List<Integer> showIndexes = new ArrayList<Integer>();
    if (modelCollection != null) {
        int lineIndex = 0;
        for (Object line : modelCollection) {
            if (line instanceof Inactivatable) {
                boolean active = ((Inactivatable) line).isActive();
                if (active) {
                    showIndexes.add(lineIndex);
                }
            }
            lineIndex++;
        }
    }

    return showIndexes;
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:30,代码来源:ActiveCollectionFilter.java


示例2: performCollectionFiltering

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Performs any filtering necessary on the collection before building the collection fields.
 *
 * <p>If showInactive is set to false and the collection line type implements {@code Inactivatable},
 * invokes the active collection filter. Then any {@link CollectionFilter} instances configured for the collection
 * group are invoked to filter the collection. Collections lines must pass all filters in order to be
 * displayed</p>
 *
 * @param view view instance that contains the collection
 * @param model object containing the views data
 * @param collectionGroup collection group component instance that will display the collection
 * @param collection collection instance that will be filtered
 */
protected List<Integer> performCollectionFiltering(View view, Object model, CollectionGroup collectionGroup,
        Collection<?> collection) {
    List<Integer> filteredIndexes = new ArrayList<Integer>();
    for (int i = 0; i < collection.size(); i++) {
        filteredIndexes.add(Integer.valueOf(i));
    }

    if (Inactivatable.class.isAssignableFrom(collectionGroup.getCollectionObjectClass()) && !collectionGroup
            .isShowInactiveLines()) {
        List<Integer> activeIndexes = collectionGroup.getActiveCollectionFilter().filter(view, model,
                collectionGroup);
        filteredIndexes = ListUtils.intersection(filteredIndexes, activeIndexes);
    }

    for (CollectionFilter collectionFilter : collectionGroup.getFilters()) {
        List<Integer> indexes = collectionFilter.filter(view, model, collectionGroup);
        filteredIndexes = ListUtils.intersection(filteredIndexes, indexes);
        if (filteredIndexes.isEmpty()) {
            break;
        }
    }

    return filteredIndexes;
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:38,代码来源:CollectionGroupBuilder.java


示例3: detectBlockingRecord

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Implementation which calls the legacy {@link #hasABlockingRecord(org.kuali.rice.krad.bo.BusinessObject, org.kuali.rice.krad.datadictionary.InactivationBlockingMetadata)}
 * if the given data object is a legacy object. Calls new code to make the equivalent check if the given object is
 * non-legacy.
 */
@Override
public boolean detectBlockingRecord(Object dataObject, InactivationBlockingMetadata inactivationBlockingMetadata) {
    if (LegacyUtils.useLegacyForObject(dataObject)) {
        return hasABlockingRecord((BusinessObject)dataObject, inactivationBlockingMetadata);
    }
    QueryByCriteria criteria = buildInactivationBlockerCriteria(dataObject, inactivationBlockingMetadata);
    if (criteria != null) {
        Class<?> blockingType = inactivationBlockingMetadata.getBlockingDataObjectClass();
        QueryResults<?> potentialBlockingRecords = getDataObjectService().findMatching(blockingType, criteria);
        for (Object result : potentialBlockingRecords.getResults()) {
            if (!(result instanceof Inactivatable)) {
                throw new IllegalStateException("Blocking records must implement Inactivatable, but encountered one which does not: " + result);
            }
            Inactivatable inactivatable = (Inactivatable)result;
            if (inactivatable.isActive()) {
                return true;
            }
        }
    }
    // if criteria is null, means that we couldn't perform a query, and hence, need to return false
    return false;
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:28,代码来源:InactivationBlockingDetectionServiceImpl.java


示例4: isRowHideableForMaintenanceDocument

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Determines whether a business object is hidable on a maintenance document.  Hidable means that if the user chose to hide the inactive
 * elements in the collection in which the passed in BOs reside, then the BOs would be hidden
 * 
 * @param lineBusinessObject the BO in the new maintainable, should be of type {@link BusinessObject} and {@link Inquirable}
 * @param oldLineBusinessObject the corresponding BO in the old maintainable, should be of type {@link BusinessObject} and 
 * {@link Inquirable}
 * @return whether the BOs are eligible to be hidden if the user decides to hide them
 */
protected static boolean isRowHideableForMaintenanceDocument(BusinessObject lineBusinessObject, BusinessObject oldLineBusinessObject) {
    if (oldLineBusinessObject != null) {
    	if ( lineBusinessObject instanceof PersistableBusinessObject ) {
         if (((PersistableBusinessObject) lineBusinessObject).isNewCollectionRecord()) {
             // new records are never hidden, regardless of active status
             return false;
         }
    	}
        if (!((Inactivatable) lineBusinessObject).isActive() && !((Inactivatable) oldLineBusinessObject).isActive()) {
            // records with an old and new collection elements of NOT active are eligible to be hidden
            return true;
        }
    }
    return false;
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:25,代码来源:SectionBridge.java


示例5: filter

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Iterates through the collection and if the collection line type implements <code>Inactivatable</code>,
 * active indexes are added to the show indexes list
 *
 * @see CollectionFilter#filter(org.kuali.rice.krad.uif.view.View, Object, org.kuali.rice.krad.uif.container.CollectionGroup)
 */
@Override
public List<Integer> filter(View view, Object model, CollectionGroup collectionGroup) {
    // get the collection for this group from the model
    List<Object> modelCollection =
            ObjectPropertyUtils.getPropertyValue(model, collectionGroup.getBindingInfo().getBindingPath());

    // iterate through and add only active indexes
    List<Integer> showIndexes = new ArrayList<Integer>();
    if (modelCollection != null) {
        int lineIndex = 0;
        for (Object line : modelCollection) {
            if (line instanceof Inactivatable) {
                boolean active = ((Inactivatable) line).isActive();
                if (active) {
                    showIndexes.add(lineIndex);
                }
            }
            lineIndex++;
        }
    }

    return showIndexes;
}
 
开发者ID:aapotts,项目名称:kuali_rice,代码行数:30,代码来源:ActiveCollectionFilter.java


示例6: performCollectionFiltering

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Performs any filtering necessary on the collection before building the collection fields
 *
 * <p>
 * If showInactive is set to false and the collection line type implements {@code Inactivatable},
 * invokes the active collection filter. Then any {@link CollectionFilter} instances configured for the collection
 * group are invoked to filter the collection. Collections lines must pass all filters in order to be
 * displayed
 * </p>
 *
 * @param view view instance that contains the collection
 * @param model object containing the views data
 * @param collectionGroup collection group component instance that will display the collection
 * @param collection collection instance that will be filtered
 */
protected List<Integer> performCollectionFiltering(View view, Object model, CollectionGroup collectionGroup,
        Collection<?> collection) {
    List<Integer> filteredIndexes = new ArrayList<Integer>();
    for (int i = 0; i < collection.size(); i++) {
        filteredIndexes.add(Integer.valueOf(i));
    }

    if (Inactivatable.class.isAssignableFrom(collectionGroup.getCollectionObjectClass()) && !collectionGroup
            .isShowInactiveLines()) {
        List<Integer> activeIndexes = collectionGroup.getActiveCollectionFilter().filter(view, model,
                collectionGroup);
        filteredIndexes = ListUtils.intersection(filteredIndexes, activeIndexes);
    }

    for (CollectionFilter collectionFilter : collectionGroup.getFilters()) {
        List<Integer> indexes = collectionFilter.filter(view, model, collectionGroup);
        filteredIndexes = ListUtils.intersection(filteredIndexes, indexes);
        if (filteredIndexes.isEmpty()) {
            break;
        }
    }

    return filteredIndexes;
}
 
开发者ID:aapotts,项目名称:kuali_rice,代码行数:40,代码来源:CollectionGroupBuilder.java


示例7: filter

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Iterates through the collection and if the collection line type implements <code>Inactivatable</code>
 * active indexes are added to the show indexes list
 *
 * <p>
 * In the case of a new line being added, the user is not allowed to hide the record (even if it is inactive).
 * Likewise in the case of an edit where the active flag has changed between the old and new side, the user
 * is not allowed to hide
 * </p>
 *
 * {@inheritDoc}
 */
@Override
public List<Integer> filter(View view, Object model, CollectionGroup collectionGroup) {

    // get the collection for this group from the model
    List<Object> newCollection =
            ObjectPropertyUtils.getPropertyValue(model, collectionGroup.getBindingInfo().getBindingPath());

    // Get collection from old data object
    List<Object> oldCollection = null;
    String oldCollectionBindingPath = null;
    oldCollectionBindingPath = StringUtils.replaceOnce(collectionGroup.getBindingInfo().getBindingPath(),
                collectionGroup.getBindingInfo().getBindingObjectPath(), oldBindingObjectPath);
    oldCollection = ObjectPropertyUtils.getPropertyValue(model, oldCollectionBindingPath);

    // iterate through and add only active indexes
    List<Integer> showIndexes = new ArrayList<Integer>();
    for (int i = 0; i < newCollection.size(); i++) {
        Object line = newCollection.get(i);
        if (line instanceof Inactivatable) {
            boolean active = ((Inactivatable) line).isActive();
            if ((oldCollection != null) && (oldCollection.size() > i)) {
                // if active status has changed, show record
                Inactivatable oldLine = (Inactivatable) oldCollection.get(i);
                if (oldLine.isActive()) {
                    showIndexes.add(i);
                }
            } else {
                // TODO: if newly added line, show record
                // If only new and no old add the newline
                if (active) {
                    showIndexes.add(i);
                }
            }
        }
    }

    return showIndexes;
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:51,代码来源:MaintenanceActiveCollectionFilter.java


示例8: addActiveCriteriaIfNecessary

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Adds the 'active' property criteria to the criteria fields if the BO is inactivatable and their is
 * not already a lookup field for the active property.
 */
protected void addActiveCriteriaIfNecessary() {
    boolean isInactivatableClass = Inactivatable.class.isAssignableFrom(dataObjectClass);

    if (!autoAddActiveCriteria || !isInactivatableClass) {
        return;
    }

    boolean hasActiveCriteria = false;
    for (Component field : getCriteriaFields()) {
        if (((InputField) field).getPropertyName().equals(UifPropertyPaths.ACTIVE)) {
            hasActiveCriteria = true;
        }
    }

    if (hasActiveCriteria) {
        return;
    }

    AttributeDefinition attributeDefinition =
            KRADServiceLocatorWeb.getDataDictionaryService().getAttributeDefinition(dataObjectClass.getName(),
                    UifPropertyPaths.ACTIVE);

    LookupInputField activeLookupField;
    if (attributeDefinition == null) {
        activeLookupField = (LookupInputField) ComponentFactory.getNewComponentInstance(
                ComponentFactory.LOOKUP_ACTIVE_INPUT_FIELD);
    } else {
        activeLookupField = (LookupInputField) ComponentFactory.getNewComponentInstance(
                ComponentFactory.LOOKUP_INPUT_FIELD);

        activeLookupField.setPropertyName(UifPropertyPaths.ACTIVE);
        activeLookupField.copyFromAttributeDefinition(attributeDefinition);
    }

    getCriteriaFields().add(activeLookupField);
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:41,代码来源:LookupView.java


示例9: validateReferenceIsActive

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * @see org.kuali.rice.krad.service.DictionaryValidationService#validateReferenceIsActive(java.lang.Object
 * dataObject,
 * String)
 */
@Override
public boolean validateReferenceIsActive(Object dataObject, String referenceName) {
    // attempt to retrieve the specified object from the db
    Object referenceDataObject = getLegacyDataAdapter().getReferenceIfExists(dataObject, referenceName);
    if (referenceDataObject == null) {
        return false;
    }
    // mutable is related only to BusinessObject classes
    if (!(referenceDataObject instanceof Inactivatable) || ((Inactivatable) referenceDataObject).isActive()) {
        return true;
    }

    return false;
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:20,代码来源:DictionaryValidationServiceImpl.java


示例10: validateReferenceExistsAndIsActive

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * @see org.kuali.rice.krad.service.DictionaryValidationService#validateReferenceExistsAndIsActive(java.lang.Object
 * dataObject,
 * String, String, String)
 */
@Override
public boolean validateReferenceExistsAndIsActive(Object dataObject, String referenceName,
        String attributeToHighlightOnFail, String displayFieldName) {

    // if we're dealing with a nested attribute, we need to resolve down to the BO where the primitive attribute is located
    // this is primarily to deal with the case of a defaultExistenceCheck that uses an "extension", i.e referenceName
    // would be extension.attributeName
    if (PropertyAccessorUtils.isNestedOrIndexedProperty(referenceName)) {
        String nestedAttributePrefix = KRADUtils.getNestedAttributePrefix(referenceName);
        String nestedAttributePrimitive = KRADUtils.getNestedAttributePrimitive(referenceName);
        Object nestedObject = KradDataServiceLocator.getDataObjectService().wrap(dataObject)
                .getPropertyValueNullSafe(nestedAttributePrefix);
        return validateReferenceExistsAndIsActive(nestedObject, nestedAttributePrimitive,
                attributeToHighlightOnFail, displayFieldName);
    }

    boolean hasReferences = validateFkFieldsPopulated(dataObject, referenceName);
    boolean referenceExists = hasReferences && validateReferenceExists(dataObject, referenceName);
    boolean canIncludeActiveReference = referenceExists && (!(dataObject instanceof Inactivatable) ||
            ((Inactivatable) dataObject).isActive());
    boolean referenceActive = canIncludeActiveReference && validateReferenceIsActive(dataObject, referenceName);

    if(hasReferences && !referenceExists) {
        GlobalVariables.getMessageMap().putError(attributeToHighlightOnFail, RiceKeyConstants.ERROR_EXISTENCE,
                displayFieldName);
        return false;
    } else if(canIncludeActiveReference && !referenceActive) {
        GlobalVariables.getMessageMap().putError(attributeToHighlightOnFail, RiceKeyConstants.ERROR_INACTIVE,
                displayFieldName);
        return false;
    }

    return true;
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:40,代码来源:DictionaryValidationServiceImpl.java


示例11: detectAllBlockingRecords

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Implementation which calls the legacy {@link #listAllBlockerRecords(org.kuali.rice.krad.bo.BusinessObject, org.kuali.rice.krad.datadictionary.InactivationBlockingMetadata)}
 * if the given data object is a legacy object. Calls new code to make the equivalent check if the given object is
 * non-legacy.
 */
@Override
public Collection<?> detectAllBlockingRecords(Object dataObject,
        InactivationBlockingMetadata inactivationBlockingMetadata) {
    if (LegacyUtils.useLegacyForObject(dataObject)) {
        return listAllBlockerRecords((BusinessObject) dataObject, inactivationBlockingMetadata);
    }
    List<Object> blockingRecords = new ArrayList<Object>();

    QueryByCriteria criteria = buildInactivationBlockerCriteria(dataObject, inactivationBlockingMetadata);
    if (LOG.isDebugEnabled()) {
        LOG.debug("Checking for blocker records for object: " + dataObject);
        LOG.debug("    With Metadata: " + inactivationBlockingMetadata);
        LOG.debug("    Resulting QueryByCriteria: " + criteria);
    }

    if (criteria != null) {
        Class<?> blockingType = inactivationBlockingMetadata.getBlockingDataObjectClass();
        QueryResults<?> potentialBlockingRecords = getDataObjectService().findMatching(blockingType, criteria);
        for (Object result : potentialBlockingRecords.getResults()) {
            if (!(result instanceof Inactivatable)) {
                throw new IllegalStateException("Blocking records must implement Inactivatable, but encountered one which does not: " + result);
            }
            Inactivatable inactivatable = (Inactivatable)result;
            if (inactivatable.isActive()) {
                blockingRecords.add(result);
            }
        }
    }

    return blockingRecords;
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:37,代码来源:InactivationBlockingDetectionServiceImpl.java


示例12: performInitialization

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * The following initialization is performed:
 *
 * <ul>
 * <li>Set the abstractTypeClasses map for the lookup object path</li>
 * </ul>
 *
 * @see org.kuali.rice.krad.uif.container.ContainerBase#performInitialization(org.kuali.rice.krad.uif.view.View,
 *      java.lang.Object)
 */
@Override
public void performInitialization(View view, Object model) {

    boolean isInactivatableClass = Inactivatable.class.isAssignableFrom(dataObjectClassName);

    if (autoAddActiveCriteria && isInactivatableClass) {
        autoAddActiveCriteria();
    }

    initializeGroups();

    // since we don't have these as prototypes need to assign ids here
    view.assignComponentIds(getCriteriaGroup());
    view.assignComponentIds(getResultsGroup());

    if (getItems().isEmpty()) {
        setItems(Arrays.asList(getCriteriaGroup(), getResultsGroup()));
    }

    super.performInitialization(view, model);

    // if this is a multi-value lookup, don't show return column
    if (multipleValuesSelect) {
        hideReturnLinks = true;
    }

    getObjectPathToConcreteClassMapping().put(UifPropertyPaths.LOOKUP_CRITERIA, getDataObjectClassName());
    if (StringUtils.isNotBlank(getDefaultBindingObjectPath())) {
        getObjectPathToConcreteClassMapping().put(getDefaultBindingObjectPath(), getDataObjectClassName());
    }
}
 
开发者ID:aapotts,项目名称:kuali_rice,代码行数:42,代码来源:LookupView.java


示例13: filter

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Iterates through the collection and if the collection line type implements <code>Inactivatable</code>
 * active indexes are added to the show indexes list
 *
 * <p>
 * In the case of a new line being added, the user is not allowed to hide the record (even if it is inactive).
 * Likewise in the case of an edit where the active flag has changed between the old and new side, the user
 * is not allowed to hide
 * </p>
 *
 * @see CollectionFilter#filter(org.kuali.rice.krad.uif.view.View, Object, org.kuali.rice.krad.uif.container.CollectionGroup)
 */
@Override
public List<Integer> filter(View view, Object model, CollectionGroup collectionGroup) {

    // get the collection for this group from the model
    List<Object> newCollection =
            ObjectPropertyUtils.getPropertyValue(model, collectionGroup.getBindingInfo().getBindingPath());

    // Get collection from old data object
    List<Object> oldCollection = null;
    String oldCollectionBindingPath = null;
    oldCollectionBindingPath = StringUtils.replaceOnce(collectionGroup.getBindingInfo().getBindingPath(),
                collectionGroup.getBindingInfo().getBindingObjectPath(), oldBindingObjectPath);
    oldCollection = ObjectPropertyUtils.getPropertyValue(model, oldCollectionBindingPath);

    // iterate through and add only active indexes
    List<Integer> showIndexes = new ArrayList<Integer>();
    for (int i = 0; i < newCollection.size(); i++) {
        Object line = newCollection.get(i);
        if (line instanceof Inactivatable) {
            boolean active = ((Inactivatable) line).isActive();
            if ((oldCollection != null) && (oldCollection.size() > i)) {
                // if active status has changed, show record
                Inactivatable oldLine = (Inactivatable) oldCollection.get(i);
                if (oldLine.isActive()) {
                    showIndexes.add(i);
                }
            } else {
                // TODO: if newly added line, show record
                // If only new and no old add the newline
                if (active) {
                    showIndexes.add(i);
                }
            }
        }
    }

    return showIndexes;
}
 
开发者ID:aapotts,项目名称:kuali_rice,代码行数:51,代码来源:MaintenanceActiveCollectionFilter.java


示例14: isRowHideableForMaintenanceDocument

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
     * Determines whether a business object is hidable on a maintenance document.  Hidable means that if the user chose to hide the inactive
     * elements in the collection in which the passed in BOs reside, then the BOs would be hidden
     * 
     * @param lineBusinessObject the BO in the new maintainable, should be of type {@link PersistableBusinessObject} and {@link Inquirable}
     * @param oldLineBusinessObject the corresponding BO in the old maintainable, should be of type {@link PersistableBusinessObject} and 
     * {@link Inquirable}
     * @return whether the BOs are eligible to be hidden if the user decides to hide them
     */
    protected static boolean isRowHideableForMaintenanceDocument(BusinessObject lineBusinessObject, BusinessObject oldLineBusinessObject) {
        if (oldLineBusinessObject != null) {
            if (((PersistableBusinessObject) lineBusinessObject).isNewCollectionRecord()) {
                // new records are never hidden, regardless of active status
                return false;
}
            if (!((Inactivatable) lineBusinessObject).isActive() && !((Inactivatable) oldLineBusinessObject).isActive()) {
                // records with an old and new collection elements of NOT active are eligible to be hidden
                return true;
            }
        }
        return false;
    }
 
开发者ID:aapotts,项目名称:kuali_rice,代码行数:23,代码来源:SectionBridge.java


示例15: isRowHideableForInquiry

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Determines whether a business object is hidable on an inquiry screen.  Hidable means that if the user chose to hide the inactive
 * elements in the collection in which the passed in BO resides, then the BO would be hidden
 * 
 * @param lineBusinessObject the collection element BO, should be of type {@link BusinessObject} and {@link Inquirable}
 * @return whether the BO is eligible to be hidden if the user decides to hide them
 */
protected static boolean isRowHideableForInquiry(BusinessObject lineBusinessObject) {
    return !((Inactivatable) lineBusinessObject).isActive();
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:11,代码来源:SectionBridge.java


示例16: containsActiveIndicator

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Checks whether the class implements the Inactivatable interface.
 *
 * NOTE: This is different than earlier checks, as it assumes that the active flag
 * is persistent.
 *
 * @param clazz
 * @return boolean if active column is mapped for Class
 */
private <T> boolean containsActiveIndicator(Class<T> clazz) {
	return Inactivatable.class.isAssignableFrom(clazz);
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:13,代码来源:KeyValuesServiceImpl.java


示例17: isInactivating

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Determines if the given document is inactivating the balance type being maintained
 * @param document the maintenance document maintaining a balance type
 * @return true if the document is inactivating that balance type, false otherwise
 */
protected boolean isInactivating(MaintenanceDocument document) {
    if (!document.isEdit() || document.getOldMaintainableObject() == null) return false;
    return ((Inactivatable)document.getOldMaintainableObject().getBusinessObject()).isActive() && !((Inactivatable)document.getNewMaintainableObject().getBusinessObject()).isActive();
}
 
开发者ID:VU-libtech,项目名称:OLE-INST,代码行数:10,代码来源:BalanceTypeRule.java


示例18: isRowHideableForInquiry

import org.kuali.rice.core.api.mo.common.active.Inactivatable; //导入依赖的package包/类
/**
 * Determines whether a business object is hidable on an inquiry screen.  Hidable means that if the user chose to hide the inactive
 * elements in the collection in which the passed in BO resides, then the BO would be hidden
 * 
 * @param lineBusinessObject the collection element BO, should be of type {@link PersistableBusinessObject} and {@link Inquirable}
 * @return whether the BO is eligible to be hidden if the user decides to hide them
 */
protected static boolean isRowHideableForInquiry(BusinessObject lineBusinessObject) {
    return !((Inactivatable) lineBusinessObject).isActive();
}
 
开发者ID:aapotts,项目名称:kuali_rice,代码行数:11,代码来源:SectionBridge.java



注:本文中的org.kuali.rice.core.api.mo.common.active.Inactivatable类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java SecureBulkLoadHFilesRequest类代码示例发布时间:2022-05-22
下一篇:
Java SevenZFile类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap