本文整理了Java中org.dspace.content.Bitstream.<init>()
方法的一些代码示例,展示了Bitstream.<init>()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Bitstream.<init>()
方法的具体详情如下:
包路径:org.dspace.content.Bitstream
类名称:Bitstream
方法名:<init>
[英]Protected constructor, create object using: org.dspace.content.service.BitstreamService#create(Context,Bundle,InputStream)or org.dspace.content.service.BitstreamService#create(Context,InputStream)
[中]受保护的构造函数,使用:org创建对象。数据空间。所容纳之物服务BitstreamService#创建(上下文、捆绑、输入流)或组织。数据空间。所容纳之物服务BitstreamService#创建(上下文、输入流)
代码示例来源:origin: stackoverflow.com
Bitstream bitstream = new Bitstream(inputStream);
Decoder decoder = new Decoder();
代码示例来源:origin: DSpace/DSpace
@Override
public Bitstream create(Context context, InputStream is) throws IOException, SQLException {
// Store the bits
UUID bitstreamID = bitstreamStorageService.store(context, bitstreamDAO.create(context, new Bitstream()), is);
log.info(LogManager.getHeader(context, "create_bitstream",
"bitstream_id=" + bitstreamID));
// Set the format to "unknown"
Bitstream bitstream = find(context, bitstreamID);
setFormat(context, bitstream, null);
context.addEvent(
new Event(Event.CREATE, Constants.BITSTREAM, bitstreamID, null, getIdentifiers(context, bitstream)));
return bitstream;
}
代码示例来源:origin: stackoverflow.com
try
Bitstream m_bitstream = new Bitstream(pis);
aff_properties.put("mp3.header.pos", new Integer(m_bitstream.header_pos()));
Header m_header = m_bitstream.readFrame();
代码示例来源:origin: stackoverflow.com
.openConnection()
.getInputStream();
final Bitstream bitstream = new Bitstream(in);
代码示例来源:origin: stackoverflow.com
InputStream inputStream = new BufferedInputStream(new FileInputStream(file), 8 * 1024);
try {
Bitstream bitstream = new Bitstream(inputStream);
Decoder decoder = new Decoder();
代码示例来源:origin: stackoverflow.com
Bitstream bitstream = new Bitstream(is);
代码示例来源:origin: stackoverflow.com
Bitstream bitstream = new Bitstream(in);
Decoder decoder = new Decoder();
代码示例来源:origin: DSpace/DSpace
throws IOException, SQLException, AuthorizeException {
Bitstream bitstream = bitstreamDAO.create(context, new Bitstream());
bitstreamStorageService.register(
context, bitstream, assetstore, bitstreamPath);
代码示例来源:origin: DSpace/DSpace
@Override
public Bitstream clone(Context context, Bitstream bitstream)
throws SQLException {
// Create a new bitstream with a new ID.
Bitstream clonedBitstream = bitstreamDAO.create(context, new Bitstream());
// Set the internal identifier, file size, checksum, and
// checksum algorithm as same as the given bitstream.
clonedBitstream.setInternalId(bitstream.getInternalId());
clonedBitstream.setSizeBytes(bitstream.getSizeBytes());
clonedBitstream.setChecksum(bitstream.getChecksum());
clonedBitstream.setChecksumAlgorithm(bitstream.getChecksumAlgorithm());
clonedBitstream.setFormat(bitstream.getBitstreamFormat());
try {
//Update our bitstream but turn off the authorization system since permissions
//haven't been set at this point in time.
context.turnOffAuthorisationSystem();
update(context, clonedBitstream);
} catch (AuthorizeException e) {
log.error(e);
//Can never happen since we turn off authorization before we update
} finally {
context.restoreAuthSystemState();
}
return clonedBitstream;
}
内容来源于网络,如有侵权,请联系作者删除!