org.jetbrains.jet.descriptors.serialization
Class JavaProtoBufUtil

java.lang.Object
  extended by org.jetbrains.jet.descriptors.serialization.JavaProtoBufUtil

public class JavaProtoBufUtil
extends java.lang.Object


Nested Class Summary
static class JavaProtoBufUtil.PropertyData
           
 
Method Summary
static byte[] decodeBytes(java.lang.String[] data)
          Converts encoded array of String obtained by encodeBytes(byte[]) back to a byte array.
static java.lang.String[] encodeBytes(byte[] data)
          Converts a byte array of serialized data to an array of String satisfying JVM annotation value argument restrictions: Each string's length should be no more than 65535 UTF-8 representation of each string cannot contain bytes in the range 0xf0..0xff
static com.google.protobuf.ExtensionRegistryLite getExtensionRegistry()
           
static boolean isStaticFieldInOuter(ProtoBuf.Callable proto)
           
static org.jetbrains.asm4.commons.Method loadMethodSignature(ProtoBuf.Callable proto, NameResolver nameResolver)
           
static JavaProtoBufUtil.PropertyData loadPropertyData(ProtoBuf.Callable proto, NameResolver nameResolver)
           
static org.jetbrains.asm4.commons.Method loadPropertyGetterSignature(ProtoBuf.Callable proto, NameResolver nameResolver)
           
static org.jetbrains.asm4.commons.Method loadPropertySetterSignature(ProtoBuf.Callable proto, NameResolver nameResolver)
           
static Name loadSrcClassName(ProtoBuf.Callable proto, NameResolver nameResolver)
           
static ClassData readClassDataFrom(java.lang.String[] data)
           
static PackageData readPackageDataFrom(java.lang.String[] data)
           
static void saveMethodSignature(ProtoBuf.Callable.Builder proto, org.jetbrains.asm4.commons.Method method, NameTable nameTable)
           
static void savePropertySignature(ProtoBuf.Callable.Builder proto, org.jetbrains.asm4.Type fieldType, java.lang.String fieldName, boolean isStaticInOuter, java.lang.String syntheticMethodName, org.jetbrains.asm4.commons.Method getter, org.jetbrains.asm4.commons.Method setter, NameTable nameTable)
           
static void saveSrcClassName(ProtoBuf.Callable.Builder proto, Name name, NameTable nameTable)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

loadMethodSignature

@Nullable
public static org.jetbrains.asm4.commons.Method loadMethodSignature(@NotNull
                                                                             ProtoBuf.Callable proto,
                                                                             @NotNull
                                                                             NameResolver nameResolver)

loadPropertyGetterSignature

@Nullable
public static org.jetbrains.asm4.commons.Method loadPropertyGetterSignature(@NotNull
                                                                                     ProtoBuf.Callable proto,
                                                                                     @NotNull
                                                                                     NameResolver nameResolver)

loadPropertySetterSignature

@Nullable
public static org.jetbrains.asm4.commons.Method loadPropertySetterSignature(@NotNull
                                                                                     ProtoBuf.Callable proto,
                                                                                     @NotNull
                                                                                     NameResolver nameResolver)

loadPropertyData

@Nullable
public static JavaProtoBufUtil.PropertyData loadPropertyData(@NotNull
                                                                      ProtoBuf.Callable proto,
                                                                      @NotNull
                                                                      NameResolver nameResolver)

loadSrcClassName

@Nullable
public static Name loadSrcClassName(@NotNull
                                             ProtoBuf.Callable proto,
                                             @NotNull
                                             NameResolver nameResolver)

isStaticFieldInOuter

public static boolean isStaticFieldInOuter(@NotNull
                                           ProtoBuf.Callable proto)

saveMethodSignature

public static void saveMethodSignature(@NotNull
                                       ProtoBuf.Callable.Builder proto,
                                       @NotNull
                                       org.jetbrains.asm4.commons.Method method,
                                       @NotNull
                                       NameTable nameTable)

savePropertySignature

public static void savePropertySignature(@NotNull
                                         ProtoBuf.Callable.Builder proto,
                                         @Nullable
                                         org.jetbrains.asm4.Type fieldType,
                                         @Nullable
                                         java.lang.String fieldName,
                                         boolean isStaticInOuter,
                                         @Nullable
                                         java.lang.String syntheticMethodName,
                                         @Nullable
                                         org.jetbrains.asm4.commons.Method getter,
                                         @Nullable
                                         org.jetbrains.asm4.commons.Method setter,
                                         @NotNull
                                         NameTable nameTable)

saveSrcClassName

public static void saveSrcClassName(@NotNull
                                    ProtoBuf.Callable.Builder proto,
                                    @NotNull
                                    Name name,
                                    @NotNull
                                    NameTable nameTable)

getExtensionRegistry

@NotNull
public static com.google.protobuf.ExtensionRegistryLite getExtensionRegistry()

readClassDataFrom

@NotNull
public static ClassData readClassDataFrom(@NotNull
                                                  java.lang.String[] data)

readPackageDataFrom

@NotNull
public static PackageData readPackageDataFrom(@NotNull
                                                      java.lang.String[] data)

encodeBytes

@NotNull
public static java.lang.String[] encodeBytes(@NotNull
                                                     byte[] data)
Converts a byte array of serialized data to an array of String satisfying JVM annotation value argument restrictions:
  1. Each string's length should be no more than 65535
  2. UTF-8 representation of each string cannot contain bytes in the range 0xf0..0xff


decodeBytes

@NotNull
public static byte[] decodeBytes(@NotNull
                                         java.lang.String[] data)
Converts encoded array of String obtained by encodeBytes(byte[]) back to a byte array.