Class Platform4


  • public final class Platform4
    extends java.lang.Object
    • Constructor Detail

      • Platform4

        public Platform4()
    • Method Detail

      • canSetAccessible

        public static final boolean canSetAccessible()
      • createReferenceQueue

        public static final java.lang.Object createReferenceQueue()
      • createWeakReference

        public static java.lang.Object createWeakReference​(java.lang.Object obj)
      • createActiveObjectReference

        public static final java.lang.Object createActiveObjectReference​(java.lang.Object referenceQueue,
                                                                         java.lang.Object objectReference,
                                                                         java.lang.Object obj)
      • deserialize

        public static java.lang.Object deserialize​(byte[] bytes)
      • doubleToLong

        public static final long doubleToLong​(double a_double)
      • evaluationEvaluate

        public static final void evaluationEvaluate​(java.lang.Object a_evaluation,
                                                    Candidate a_candidate)
      • collectionToArray

        public static java.lang.Object[] collectionToArray​(ObjectContainerBase stream,
                                                           java.lang.Object obj)
        may be needed for YapConfig processID() at a later date
      • extendConfiguration

        public static Config4Class extendConfiguration​(ReflectClass clazz,
                                                       Configuration config,
                                                       Config4Class classConfig)
        Should create additional configuration, for example through reflection on annotations. - If a valid configuration is passed as classConfig, any additional configuration, if available, should be applied to this object, and this object should be returned. - If classConfig is null and there is no additional configuration, null should be returned. - If classConfig is null and there is additional configuration, this code should create and register a new configuration via config.objectClass(), apply additional configuration there and return this new instance. The reason for this dispatch is to avoid creation of a configuration for a class that doesn't need configuration at all.
        Parameters:
        clazz - The class to be searched for additional configuration information
        config - The global database configuration
        classConfig - A class configuration, if one already exists
        Returns:
        classConfig, if not null, a newly created ObjectClass otherwise.
      • forEachCollectionElement

        public static final void forEachCollectionElement​(java.lang.Object obj,
                                                          Visitor4 visitor)
      • format

        public static final java.lang.String format​(java.util.Date date,
                                                    boolean showTime)
      • getDefaultConfiguration

        public static final void getDefaultConfiguration​(Config4Impl config)
      • getTypeForClass

        public static java.lang.Object getTypeForClass​(java.lang.Object obj)
      • needsLockFileThread

        public static boolean needsLockFileThread()
      • hasWeakReferences

        public static final boolean hasWeakReferences()
      • isConnected

        public static boolean isConnected​(java.net.Socket socket)
      • isStruct

        public static final boolean isStruct​(ReflectClass claxx)
        Returns true if claxx represents a .net struct (a value type with members in the type handler jargon).
        Parameters:
        claxx -
      • jdk

        public static JDK jdk()
      • isSimple

        public static boolean isSimple​(java.lang.Class clazz)
      • link

        public static void link()
      • lockFile

        public static final void lockFile​(java.lang.String path,
                                          java.lang.Object file)
      • unlockFile

        public static final void unlockFile​(java.lang.String path,
                                            java.lang.Object file)
      • longToDouble

        public static final double longToDouble​(long a_long)
      • callConstructor

        public static boolean callConstructor()
      • pollReferenceQueue

        public static final void pollReferenceQueue​(java.lang.Object a_stream,
                                                    java.lang.Object a_referenceQueue)
      • registerCollections

        public static void registerCollections​(GenericReflector reflector)
      • serialize

        public static final byte[] serialize​(java.lang.Object obj)
                                      throws java.lang.Exception
        Throws:
        java.lang.Exception
      • setAccessible

        public static final void setAccessible​(java.lang.Object a_accessible)
      • storeStaticFieldValues

        public static boolean storeStaticFieldValues​(Reflector reflector,
                                                     ReflectClass claxx)
      • updateClassName

        public static byte[] updateClassName​(byte[] bytes)
      • weakReferenceTarget

        public static java.lang.Object weakReferenceTarget​(java.lang.Object weakRef)
      • wrapEvaluation

        public static java.lang.Object wrapEvaluation​(java.lang.Object evaluation)
      • isTransient

        public static boolean isTransient​(ReflectClass claxx)
        Parameters:
        claxx -
      • reflectorForType

        public static Reflector reflectorForType​(java.lang.Class clazz)
      • now

        public static java.util.Date now()
      • useNativeSerialization

        public static boolean useNativeSerialization()
      • registerPlatformHandlers

        public static void registerPlatformHandlers​(ObjectContainerBase container)
      • nullableTypeFor

        public static java.lang.Class nullableTypeFor​(java.lang.Class primitiveJavaClass)
      • nullValue

        public static java.lang.Object nullValue​(java.lang.Class clazz)
      • primitiveTypes

        public static java.lang.Class[] primitiveTypes()
      • throwUncheckedException

        public static void throwUncheckedException​(java.lang.Throwable origExc)
      • toSByte

        public static final byte toSByte​(byte b)
      • newStorage

        public static Storage newStorage()
      • asUtf8

        public static java.lang.String asUtf8​(byte[] byteArray)
      • printStackTrace

        public static void printStackTrace​(java.lang.Throwable t,
                                           java.io.PrintWriter out)