Class SDL_Locale.Buffer

All Implemented Interfaces:
AutoCloseable, Iterable<SDL_Locale>, NativeResource, Pointer
Enclosing class:
SDL_Locale

public static class SDL_Locale.Buffer extends StructBuffer<SDL_Locale, SDL_Locale.Buffer> implements NativeResource
An array of SDL_Locale structs.
  • Constructor Details

    • Buffer

      public Buffer(ByteBuffer container)
      Creates a new SDL_Locale.Buffer instance backed by the specified container.

      Changes to the container's content will be visible to the struct buffer instance and vice versa. The two buffers' position, limit, and mark values will be independent. The new buffer's position will be zero, its capacity and its limit will be the number of bytes remaining in this buffer divided by SDL_Locale.SIZEOF, and its mark will be undefined.

      The created buffer instance holds a strong reference to the container object.

    • Buffer

      public Buffer(long address, int cap)
  • Method Details

    • language

      @NativeType("char const *") public ByteBuffer language()
      Returns:
      a ByteBuffer view of the null-terminated string pointed to by the language field.
    • languageString

      @NativeType("char const *") public String languageString()
      Returns:
      the null-terminated string pointed to by the language field.
    • country

      @NativeType("char const *") public @Nullable ByteBuffer country()
      Returns:
      a ByteBuffer view of the null-terminated string pointed to by the country field.
    • countryString

      @NativeType("char const *") public @Nullable String countryString()
      Returns:
      the null-terminated string pointed to by the country field.
    • language

      public SDL_Locale.Buffer language(@NativeType("char const *") ByteBuffer value)
      Sets the address of the specified encoded string to the language field.
    • country

      public SDL_Locale.Buffer country(@NativeType("char const *") @Nullable ByteBuffer value)
      Sets the address of the specified encoded string to the country field.