Public Member Functions | Private Member Functions | Static Private Member Functions | Static Private Attributes | List of all members
com.google.protobuf.Utf8Test Class Reference
Inheritance diagram for com.google.protobuf.Utf8Test:
Inheritance graph
[legend]

Public Member Functions

void testEncode ()
 
void testEncode_insufficientSpace ()
 
void testInvalidSurrogateCodepoint ()
 
void testMaxCodepointExceeded ()
 
void testOverlongIsInvalid ()
 
void testValid ()
 

Private Member Functions

void assertEncoding_insufficientSpace (String message)
 
void assertExceptionMessage (Throwable t, int index)
 

Static Private Member Functions

static void assertEncoding (String message)
 
static void assertIsValid (byte[] data, boolean valid)
 
static byte[] encodeToByteArray (String message, int length, Utf8.Processor processor)
 
static byte[] encodeToByteBuffer (String message, int length, boolean direct, Utf8.Processor processor)
 
static String randomString (int maxCodePoint)
 

Static Private Attributes

static final int NUM_CHARS = 16384
 
static final Utf8.Processor safeProcessor = new Utf8.SafeProcessor()
 
static final Utf8.Processor unsafeProcessor = new Utf8.UnsafeProcessor()
 

Detailed Description

Unit tests for Utf8.

Definition at line 40 of file Utf8Test.java.

Member Function Documentation

◆ assertEncoding()

static void com.google.protobuf.Utf8Test.assertEncoding ( String  message)
inlinestaticprivate

Definition at line 126 of file Utf8Test.java.

◆ assertEncoding_insufficientSpace()

void com.google.protobuf.Utf8Test.assertEncoding_insufficientSpace ( String  message)
inlineprivate

Definition at line 144 of file Utf8Test.java.

◆ assertExceptionMessage()

void com.google.protobuf.Utf8Test.assertExceptionMessage ( Throwable  t,
int  index 
)
inlineprivate

Definition at line 226 of file Utf8Test.java.

◆ assertIsValid()

static void com.google.protobuf.Utf8Test.assertIsValid ( byte[]  data,
boolean  valid 
)
inlinestaticprivate

Definition at line 101 of file Utf8Test.java.

◆ encodeToByteArray()

static byte [] com.google.protobuf.Utf8Test.encodeToByteArray ( String  message,
int  length,
Utf8.Processor  processor 
)
inlinestaticprivate

Definition at line 202 of file Utf8Test.java.

◆ encodeToByteBuffer()

static byte [] com.google.protobuf.Utf8Test.encodeToByteBuffer ( String  message,
int  length,
boolean  direct,
Utf8.Processor  processor 
)
inlinestaticprivate

Definition at line 208 of file Utf8Test.java.

◆ randomString()

static String com.google.protobuf.Utf8Test.randomString ( int  maxCodePoint)
inlinestaticprivate

Definition at line 87 of file Utf8Test.java.

◆ testEncode()

void com.google.protobuf.Utf8Test.testEncode ( )
inline

Definition at line 46 of file Utf8Test.java.

◆ testEncode_insufficientSpace()

void com.google.protobuf.Utf8Test.testEncode_insufficientSpace ( )
inline

Definition at line 54 of file Utf8Test.java.

◆ testInvalidSurrogateCodepoint()

void com.google.protobuf.Utf8Test.testInvalidSurrogateCodepoint ( )
inline

Definition at line 78 of file Utf8Test.java.

◆ testMaxCodepointExceeded()

void com.google.protobuf.Utf8Test.testMaxCodepointExceeded ( )
inline

Definition at line 73 of file Utf8Test.java.

◆ testOverlongIsInvalid()

void com.google.protobuf.Utf8Test.testOverlongIsInvalid ( )
inline

Definition at line 67 of file Utf8Test.java.

◆ testValid()

void com.google.protobuf.Utf8Test.testValid ( )
inline

Definition at line 62 of file Utf8Test.java.

Member Data Documentation

◆ NUM_CHARS

final int com.google.protobuf.Utf8Test.NUM_CHARS = 16384
staticprivate

Definition at line 41 of file Utf8Test.java.

◆ safeProcessor

final Utf8.Processor com.google.protobuf.Utf8Test.safeProcessor = new Utf8.SafeProcessor()
staticprivate

Definition at line 43 of file Utf8Test.java.

◆ unsafeProcessor

final Utf8.Processor com.google.protobuf.Utf8Test.unsafeProcessor = new Utf8.UnsafeProcessor()
staticprivate

Definition at line 44 of file Utf8Test.java.


The documentation for this class was generated from the following file:


libaditof
Author(s):
autogenerated on Wed May 21 2025 02:07:08