Revision 6091
Added by Chris Jones almost 13 years ago
IdentifierManager.java | ||
---|---|---|
43 | 43 |
import edu.ucsb.nceas.metacat.database.DBConnection; |
44 | 44 |
import edu.ucsb.nceas.metacat.database.DBConnectionPool; |
45 | 45 |
import edu.ucsb.nceas.metacat.properties.PropertyService; |
46 |
import edu.ucsb.nceas.metacat.service.ObjectFormatService; |
|
47 | 46 |
import edu.ucsb.nceas.metacat.shared.ServiceException; |
48 | 47 |
import edu.ucsb.nceas.metacat.util.DocumentUtil; |
49 | 48 |
import edu.ucsb.nceas.utilities.PropertyNotFoundException; |
... | ... | |
1002 | 1001 |
//cs.setAlgorithm(ChecksumAlgorithm.convert(checksumAlgorithm)); |
1003 | 1002 |
oi.setChecksum(cs); |
1004 | 1003 |
|
1005 |
ObjectFormat oFormat = ObjectFormatService.getFormat(format);
|
|
1004 |
ObjectFormat oFormat = ObjectFormat.convert(format);
|
|
1006 | 1005 |
if(oFormat != null) |
1007 | 1006 |
{ |
1008 | 1007 |
oi.setObjectFormat(oFormat); |
1009 | 1008 |
} |
1010 | 1009 |
else |
1011 | 1010 |
{ //if there is no object format, just default to text/plain |
1012 |
oi.setObjectFormat(ObjectFormatService.getFormat("application/octet-stream"));
|
|
1011 |
oi.setObjectFormat(ObjectFormat.OCTET_STREAM);
|
|
1013 | 1012 |
} |
1014 | 1013 |
|
1015 | 1014 |
oi.setSize(size); |
Also available in: Unified diff
In order to sync up with DataONE 0.6.1 changes, I'm backing out ObjectFormatService changes temporarily in Metacat. Most functionality will be rolled back in using the DataONE 0.6.2 tag, but some methods in ObjectFormatService (such as getListFromDisk()) will be moved into d1_libclient_java.