org.fcrepo.server.security.xacml.pdp.data
Class PolicyUtils
java.lang.Object
org.fcrepo.server.security.xacml.pdp.data.PolicyUtils
public class PolicyUtils
- extends Object
Various utility methods for managing policies
- Version:
- $Id$
- Author:
- Stephen Bayliss
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PolicyUtils
public PolicyUtils()
fileToString
public String fileToString(File f)
throws MelcoePDPException
- Read file and return contents as a string
- Parameters:
f - File to read
- Returns:
-
- Throws:
PolicyStoreException
MelcoePDPException
getPolicyName
public String getPolicyName(File policy)
throws MelcoePDPException
- Throws:
MelcoePDPException
getPolicyName
public String getPolicyName(String policy)
throws MelcoePDPException
- Throws:
MelcoePDPException
getDocumentMetadata
public Map<String,String> getDocumentMetadata(byte[] docData)
getDocumentMetadata
public Map<String,String> getDocumentMetadata(InputStream docIS)
- Obtains the metadata for the given document.
- Parameters:
docIS - the document as an InputStream
- Returns:
- the document metadata as a Map
Copyright © 2012 DuraSpace. All Rights Reserved.