本文整理汇总了Java中com.intellij.util.io.IOUtil.writeUTF方法的典型用法代码示例。如果您正苦于以下问题:Java IOUtil.writeUTF方法的具体用法?Java IOUtil.writeUTF怎么用?Java IOUtil.writeUTF使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.intellij.util.io.IOUtil
的用法示例。
在下文中一共展示了IOUtil.writeUTF方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getValueExternalizer
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@NotNull
@Override
public DataExternalizer<XsdNamespaceBuilder> getValueExternalizer() {
return new DataExternalizer<XsdNamespaceBuilder>() {
@Override
public void save(@NotNull DataOutput out, XsdNamespaceBuilder value) throws IOException {
IOUtil.writeUTF(out, value.getNamespace() == null ? "" : value.getNamespace());
IOUtil.writeUTF(out, value.getVersion() == null ? "" : value.getVersion());
writeList(out, value.getTags());
writeList(out, value.getRootTags());
}
@Override
public XsdNamespaceBuilder read(@NotNull DataInput in) throws IOException {
return new XsdNamespaceBuilder(IOUtil.readUTF(in),
IOUtil.readUTF(in),
readList(in),
readList(in));
}
};
}
示例2: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@Override
public void save(@NotNull DataOutput out, List<SourcePathAndRootIndex> value) throws IOException {
for (SourcePathAndRootIndex pair : value) {
IOUtil.writeUTF(out, pair.myPath);
out.writeInt(pair.getRootIndex());
}
}
示例3: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@Override
public void save(@NotNull DataOutput out, VirtualFileSetState value) throws IOException {
final Map<String, Long> dependencies = value.myTimestamps;
out.writeInt(dependencies.size());
for (Map.Entry<String, Long> entry : dependencies.entrySet()) {
IOUtil.writeUTF(out, entry.getKey());
out.writeLong(entry.getValue());
}
}
示例4: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@Override
public void save(@NotNull DataOutput out, VirtualFileWithDependenciesState value) throws IOException {
out.writeLong(value.mySourceTimestamp);
final Map<String, Long> dependencies = value.myDependencies;
out.writeInt(dependencies.size());
for (Map.Entry<String, Long> entry : dependencies.entrySet()) {
IOUtil.writeUTF(out, entry.getKey());
out.writeLong(entry.getValue());
}
}
示例5: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@Override
public void save(@NotNull DataOutput out, Set<MyResourceInfo> value) throws IOException {
DataInputOutputUtil.writeINT(out, value.size());
for (MyResourceInfo entry : value) {
IOUtil.writeUTF(out, entry.getResourceEntry().getType());
IOUtil.writeUTF(out, entry.getResourceEntry().getName());
IOUtil.writeUTF(out, entry.getResourceEntry().getContext());
DataInputOutputUtil.writeINT(out, entry.getOffset());
}
}
示例6: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@Override
public void save(@NotNull DataOutput out, Key value) throws IOException {
out.writeBoolean(value.isMarker);
if (value.key != null) {
IOUtil.writeUTF(out, value.key);
}
}
示例7: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@Override
public void save(@NotNull DataOutput out, Set<String> value) throws IOException {
DataInputOutputUtil.writeINT(out, value.size());
for (String s : value) {
IOUtil.writeUTF(out, s);
}
}
示例8: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@Override
public void save(@Nonnull DataOutput out, VirtualFileWithDependenciesState value) throws IOException {
out.writeLong(value.mySourceTimestamp);
final Map<String, Long> dependencies = value.myDependencies;
out.writeInt(dependencies.size());
for (Map.Entry<String, Long> entry : dependencies.entrySet()) {
IOUtil.writeUTF(out, entry.getKey());
out.writeLong(entry.getValue());
}
}
示例9: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@Override
public void save(DataOutput out, ArtifactPackagingItemOutputState value) throws IOException {
out.writeInt(value.myDestinations.size());
for (Pair<String, Long> pair : value.myDestinations) {
IOUtil.writeUTF(out, pair.getFirst());
out.writeLong(pair.getSecond());
}
}
示例10: getValueExternalizer
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@NotNull
@Override
public DataExternalizer<XsdNamespaceBuilder> getValueExternalizer()
{
return new DataExternalizer<XsdNamespaceBuilder>()
{
@Override
public void save(@NotNull DataOutput out, XsdNamespaceBuilder value) throws IOException
{
IOUtil.writeUTF(out, value.getNamespace() != null ? value.getNamespace() : NULL_STRING);
IOUtil.writeUTF(out, value.getVersion() != null ? value.getVersion() : NULL_STRING);
IOUtil.writeStringList(out, value.getTags());
IOUtil.writeStringList(out, value.getRootTags());
}
@Override
public XsdNamespaceBuilder read(@NotNull DataInput in) throws IOException
{
String namespace = IOUtil.readUTF(in);
if(NULL_STRING.equals(namespace))
{
namespace = null;
}
String version = IOUtil.readUTF(in);
if(NULL_STRING.equals(version))
{
version = null;
}
return new XsdNamespaceBuilder(namespace, version, IOUtil.readStringList(in), IOUtil.readStringList(in));
}
};
}
示例11: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
public void save(@NotNull DataOutput out, File value) throws IOException {
IOUtil.writeUTF(out, value.getPath());
}
示例12: save
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
public void save(@NotNull DataOutput out, Collection<String> value) throws IOException {
for (String str : value) {
IOUtil.writeUTF(out, str);
}
}
示例13: writeUTF
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
protected static void writeUTF(DataOutput out, String value) throws IOException {
IOUtil.writeUTF(out, value);
}
示例14: writeString
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
public static void writeString(DataOutput out, @NotNull String s) throws IOException {
IOUtil.writeUTF(out, s);
}
示例15: writeValue
import com.intellij.util.io.IOUtil; //导入方法依赖的package包/类
@Override
public void writeValue(DataOutput out) throws IOException {
IOUtil.writeUTF(out, myFileName);
}