本文整理汇总了Java中org.bimserver.plugins.deserializers.Deserializer.read方法的典型用法代码示例。如果您正苦于以下问题:Java Deserializer.read方法的具体用法?Java Deserializer.read怎么用?Java Deserializer.read使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.bimserver.plugins.deserializers.Deserializer
的用法示例。
在下文中一共展示了Deserializer.read方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: readModel
import org.bimserver.plugins.deserializers.Deserializer; //导入方法依赖的package包/类
@Override
protected IfcModelInterface readModel(Deserializer d) throws DeserializeException, IOException {
// The factory only reports a non-unknown type if the zip has at least
// one .ifc* file, so this should be safe.
final ZipEntry first = ifcEntries.get(0);
return d.read(zipFile.getInputStream(first), first.getName(), first.getSize());
}
示例2: readModel
import org.bimserver.plugins.deserializers.Deserializer; //导入方法依赖的package包/类
@Override
protected IfcModelInterface readModel(Deserializer d) throws DeserializeException {
return d.read(ifc);
}
示例3: readFromBytes
import org.bimserver.plugins.deserializers.Deserializer; //导入方法依赖的package包/类
public static IfcModelInterface readFromBytes(Deserializer deserializer, byte[] bytes, String filename) throws DeserializeException {
return deserializer.read(new ByteArrayInputStream(bytes), filename, bytes.length, null);
}
示例4: readFromFile
import org.bimserver.plugins.deserializers.Deserializer; //导入方法依赖的package包/类
public static IfcModelInterface readFromFile(Deserializer deserializer, Path path) throws DeserializeException, IOException {
try (InputStream fis = Files.newInputStream(path)) {
return deserializer.read(fis, path.getFileName().toString(), Files.size(path), null);
}
}