Class ThreadPoolOptionProto.Builder

All Implemented Interfaces:
Message.Builder, MessageLite.Builder, MessageLiteOrBuilder, MessageOrBuilder, Cloneable, ThreadPoolOptionProtoOrBuilder
Enclosing class:
ThreadPoolOptionProto

public static final class ThreadPoolOptionProto.Builder extends GeneratedMessage.Builder<ThreadPoolOptionProto.Builder> implements ThreadPoolOptionProtoOrBuilder
Protobuf type tensorflow.ThreadPoolOptionProto
  • Method Details

    • getDescriptor

      public static final Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

    • clear

      Specified by:
      clear in interface Message.Builder
      Specified by:
      clear in interface MessageLite.Builder
      Overrides:
      clear in class GeneratedMessage.Builder<ThreadPoolOptionProto.Builder>
    • getDescriptorForType

      public Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface Message.Builder
      Specified by:
      getDescriptorForType in interface MessageOrBuilder
      Overrides:
      getDescriptorForType in class GeneratedMessage.Builder<ThreadPoolOptionProto.Builder>
    • getDefaultInstanceForType

      public ThreadPoolOptionProto getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface MessageOrBuilder
    • build

      public ThreadPoolOptionProto build()
      Specified by:
      build in interface Message.Builder
      Specified by:
      build in interface MessageLite.Builder
    • buildPartial

      public ThreadPoolOptionProto buildPartial()
      Specified by:
      buildPartial in interface Message.Builder
      Specified by:
      buildPartial in interface MessageLite.Builder
    • mergeFrom

      public ThreadPoolOptionProto.Builder mergeFrom(Message other)
      Specified by:
      mergeFrom in interface Message.Builder
      Overrides:
      mergeFrom in class AbstractMessage.Builder<ThreadPoolOptionProto.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface MessageLiteOrBuilder
      Overrides:
      isInitialized in class GeneratedMessage.Builder<ThreadPoolOptionProto.Builder>
    • mergeFrom

      public ThreadPoolOptionProto.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface Message.Builder
      Specified by:
      mergeFrom in interface MessageLite.Builder
      Overrides:
      mergeFrom in class AbstractMessage.Builder<ThreadPoolOptionProto.Builder>
      Throws:
      IOException
    • getNumThreads

      public int getNumThreads()
      The number of threads in the pool.
      
      0 means the system picks a value based on where this option proto is used
      (see the declaration of the specific field for more info).
      
      int32 num_threads = 1;
      Specified by:
      getNumThreads in interface ThreadPoolOptionProtoOrBuilder
      Returns:
      The numThreads.
    • setNumThreads

      public ThreadPoolOptionProto.Builder setNumThreads(int value)
      The number of threads in the pool.
      
      0 means the system picks a value based on where this option proto is used
      (see the declaration of the specific field for more info).
      
      int32 num_threads = 1;
      Parameters:
      value - The numThreads to set.
      Returns:
      This builder for chaining.
    • clearNumThreads

      public ThreadPoolOptionProto.Builder clearNumThreads()
      The number of threads in the pool.
      
      0 means the system picks a value based on where this option proto is used
      (see the declaration of the specific field for more info).
      
      int32 num_threads = 1;
      Returns:
      This builder for chaining.
    • getGlobalName

      public String getGlobalName()
      The global name of the threadpool.
      
      If empty, then the threadpool is made and used according to the scope it's
      in - e.g., for a session threadpool, it is used by that session only.
      
      If non-empty, then:
      - a global threadpool associated with this name is looked
      up or created. This allows, for example, sharing one threadpool across
      many sessions (e.g., like the default behavior, if
      inter_op_parallelism_threads is not configured), but still partitioning
      into a large and small pool.
      - if the threadpool for this global_name already exists, then it is an
      error if the existing pool was created using a different num_threads
      value as is specified on this call.
      - threadpools created this way are never garbage collected.
      
      string global_name = 2;
      Specified by:
      getGlobalName in interface ThreadPoolOptionProtoOrBuilder
      Returns:
      The globalName.
    • getGlobalNameBytes

      public ByteString getGlobalNameBytes()
      The global name of the threadpool.
      
      If empty, then the threadpool is made and used according to the scope it's
      in - e.g., for a session threadpool, it is used by that session only.
      
      If non-empty, then:
      - a global threadpool associated with this name is looked
      up or created. This allows, for example, sharing one threadpool across
      many sessions (e.g., like the default behavior, if
      inter_op_parallelism_threads is not configured), but still partitioning
      into a large and small pool.
      - if the threadpool for this global_name already exists, then it is an
      error if the existing pool was created using a different num_threads
      value as is specified on this call.
      - threadpools created this way are never garbage collected.
      
      string global_name = 2;
      Specified by:
      getGlobalNameBytes in interface ThreadPoolOptionProtoOrBuilder
      Returns:
      The bytes for globalName.
    • setGlobalName

      public ThreadPoolOptionProto.Builder setGlobalName(String value)
      The global name of the threadpool.
      
      If empty, then the threadpool is made and used according to the scope it's
      in - e.g., for a session threadpool, it is used by that session only.
      
      If non-empty, then:
      - a global threadpool associated with this name is looked
      up or created. This allows, for example, sharing one threadpool across
      many sessions (e.g., like the default behavior, if
      inter_op_parallelism_threads is not configured), but still partitioning
      into a large and small pool.
      - if the threadpool for this global_name already exists, then it is an
      error if the existing pool was created using a different num_threads
      value as is specified on this call.
      - threadpools created this way are never garbage collected.
      
      string global_name = 2;
      Parameters:
      value - The globalName to set.
      Returns:
      This builder for chaining.
    • clearGlobalName

      public ThreadPoolOptionProto.Builder clearGlobalName()
      The global name of the threadpool.
      
      If empty, then the threadpool is made and used according to the scope it's
      in - e.g., for a session threadpool, it is used by that session only.
      
      If non-empty, then:
      - a global threadpool associated with this name is looked
      up or created. This allows, for example, sharing one threadpool across
      many sessions (e.g., like the default behavior, if
      inter_op_parallelism_threads is not configured), but still partitioning
      into a large and small pool.
      - if the threadpool for this global_name already exists, then it is an
      error if the existing pool was created using a different num_threads
      value as is specified on this call.
      - threadpools created this way are never garbage collected.
      
      string global_name = 2;
      Returns:
      This builder for chaining.
    • setGlobalNameBytes

      public ThreadPoolOptionProto.Builder setGlobalNameBytes(ByteString value)
      The global name of the threadpool.
      
      If empty, then the threadpool is made and used according to the scope it's
      in - e.g., for a session threadpool, it is used by that session only.
      
      If non-empty, then:
      - a global threadpool associated with this name is looked
      up or created. This allows, for example, sharing one threadpool across
      many sessions (e.g., like the default behavior, if
      inter_op_parallelism_threads is not configured), but still partitioning
      into a large and small pool.
      - if the threadpool for this global_name already exists, then it is an
      error if the existing pool was created using a different num_threads
      value as is specified on this call.
      - threadpools created this way are never garbage collected.
      
      string global_name = 2;
      Parameters:
      value - The bytes for globalName to set.
      Returns:
      This builder for chaining.