@Component public class PolicyLogic extends Object
Modifier and Type | Field and Description |
---|---|
protected static org.slf4j.Logger |
LOG |
Constructor and Description |
---|
PolicyLogic() |
Modifier and Type | Method and Description |
---|---|
<T extends PolicyTO> |
create(PolicyType type,
T policyTO) |
<T extends PolicyTO> |
delete(PolicyType type,
String key) |
<T extends PolicyTO> |
list(PolicyType type) |
<T extends PolicyTO> |
read(PolicyType type,
String key) |
T |
resolveBeanReference(Method method,
Object... args)
Resolves stored bean (if existing) referred by the given CUD method.
|
protected PolicyTO |
resolveReference(Method method,
Object... args) |
PolicyTO |
update(PolicyType type,
PolicyTO policyTO) |
@PreAuthorize(value="hasRole(\'POLICY_CREATE\')") public <T extends PolicyTO> T create(PolicyType type, T policyTO)
@PreAuthorize(value="hasRole(\'POLICY_UPDATE\')") public PolicyTO update(PolicyType type, PolicyTO policyTO)
@PreAuthorize(value="hasRole(\'POLICY_LIST\')") @Transactional(readOnly=true) public <T extends PolicyTO> List<T> list(PolicyType type)
@PreAuthorize(value="hasRole(\'POLICY_READ\')") @Transactional(readOnly=true) public <T extends PolicyTO> T read(PolicyType type, String key)
@PreAuthorize(value="hasRole(\'POLICY_DELETE\')") public <T extends PolicyTO> T delete(PolicyType type, String key)
protected PolicyTO resolveReference(Method method, Object... args) throws UnresolvedReferenceException
UnresolvedReferenceException
public T resolveBeanReference(Method method, Object... args) throws UnresolvedReferenceException
method
- method.args
- method arguments.UnresolvedReferenceException
- in case of failures, read-only methods and unresolved bean.Copyright © 2010–2023 The Apache Software Foundation. All rights reserved.