All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.android.emulator.control.TouchEvent Maven / Gradle / Ivy

There is a newer version: 0.5.8
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: emulator_controller.proto

// Protobuf Java Version: 3.25.0
package com.android.emulator.control;

/**
 * 
 * A TouchEvent contains a list of Touch objects that are in contact with
 * the touch surface.
 *
 * Touch events are delivered in sequence as specified in the touchList.
 *
 * TouchEvents are delivered to the emulated devices using ["Protocol
 * B"](https://www.kernel.org/doc/Documentation/input/multi-touch-protocol.txt)
 * 
* * Protobuf type {@code android.emulation.control.TouchEvent} */ public final class TouchEvent extends com.google.protobuf.GeneratedMessageLite< TouchEvent, TouchEvent.Builder> implements // @@protoc_insertion_point(message_implements:android.emulation.control.TouchEvent) TouchEventOrBuilder { private TouchEvent() { touches_ = emptyProtobufList(); } public static final int TOUCHES_FIELD_NUMBER = 1; private com.google.protobuf.Internal.ProtobufList touches_; /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ @java.lang.Override public java.util.List getTouchesList() { return touches_; } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ public java.util.List getTouchesOrBuilderList() { return touches_; } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ @java.lang.Override public int getTouchesCount() { return touches_.size(); } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ @java.lang.Override public com.android.emulator.control.Touch getTouches(int index) { return touches_.get(index); } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ public com.android.emulator.control.TouchOrBuilder getTouchesOrBuilder( int index) { return touches_.get(index); } private void ensureTouchesIsMutable() { com.google.protobuf.Internal.ProtobufList tmp = touches_; if (!tmp.isModifiable()) { touches_ = com.google.protobuf.GeneratedMessageLite.mutableCopy(tmp); } } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ private void setTouches( int index, com.android.emulator.control.Touch value) { value.getClass(); ensureTouchesIsMutable(); touches_.set(index, value); } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ private void addTouches(com.android.emulator.control.Touch value) { value.getClass(); ensureTouchesIsMutable(); touches_.add(value); } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ private void addTouches( int index, com.android.emulator.control.Touch value) { value.getClass(); ensureTouchesIsMutable(); touches_.add(index, value); } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ private void addAllTouches( java.lang.Iterable values) { ensureTouchesIsMutable(); com.google.protobuf.AbstractMessageLite.addAll( values, touches_); } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ private void clearTouches() { touches_ = emptyProtobufList(); } /** *
   * The list of Touch objects, note that these do not need to be unique
   * 
* * repeated .android.emulation.control.Touch touches = 1; */ private void removeTouches(int index) { ensureTouchesIsMutable(); touches_.remove(index); } public static final int DEVICE_FIELD_NUMBER = 2; private int device_; /** *
   * The display device where the touch event occurred.
   * Omitting or using the value 0 indicates the main display.
   *
   * Touch events cannot be send to devices other than 0, due to
   * https://issuetracker.google.com/issues/150699691
   * 
* * int32 device = 2; * @return The device. */ @java.lang.Override public int getDevice() { return device_; } /** *
   * The display device where the touch event occurred.
   * Omitting or using the value 0 indicates the main display.
   *
   * Touch events cannot be send to devices other than 0, due to
   * https://issuetracker.google.com/issues/150699691
   * 
* * int32 device = 2; * @param value The device to set. */ private void setDevice(int value) { device_ = value; } /** *
   * The display device where the touch event occurred.
   * Omitting or using the value 0 indicates the main display.
   *
   * Touch events cannot be send to devices other than 0, due to
   * https://issuetracker.google.com/issues/150699691
   * 
* * int32 device = 2; */ private void clearDevice() { device_ = 0; } public static com.android.emulator.control.TouchEvent parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, data); } public static com.android.emulator.control.TouchEvent parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, data, extensionRegistry); } public static com.android.emulator.control.TouchEvent parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, data); } public static com.android.emulator.control.TouchEvent parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, data, extensionRegistry); } public static com.android.emulator.control.TouchEvent parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, data); } public static com.android.emulator.control.TouchEvent parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, data, extensionRegistry); } public static com.android.emulator.control.TouchEvent parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, input); } public static com.android.emulator.control.TouchEvent parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, input, extensionRegistry); } public static com.android.emulator.control.TouchEvent parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return parseDelimitedFrom(DEFAULT_INSTANCE, input); } public static com.android.emulator.control.TouchEvent parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return parseDelimitedFrom(DEFAULT_INSTANCE, input, extensionRegistry); } public static com.android.emulator.control.TouchEvent parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, input); } public static com.android.emulator.control.TouchEvent parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageLite.parseFrom( DEFAULT_INSTANCE, input, extensionRegistry); } public static Builder newBuilder() { return (Builder) DEFAULT_INSTANCE.createBuilder(); } public static Builder newBuilder(com.android.emulator.control.TouchEvent prototype) { return DEFAULT_INSTANCE.createBuilder(prototype); } /** *
   * A TouchEvent contains a list of Touch objects that are in contact with
   * the touch surface.
   *
   * Touch events are delivered in sequence as specified in the touchList.
   *
   * TouchEvents are delivered to the emulated devices using ["Protocol
   * B"](https://www.kernel.org/doc/Documentation/input/multi-touch-protocol.txt)
   * 
* * Protobuf type {@code android.emulation.control.TouchEvent} */ public static final class Builder extends com.google.protobuf.GeneratedMessageLite.Builder< com.android.emulator.control.TouchEvent, Builder> implements // @@protoc_insertion_point(builder_implements:android.emulation.control.TouchEvent) com.android.emulator.control.TouchEventOrBuilder { // Construct using com.android.emulator.control.TouchEvent.newBuilder() private Builder() { super(DEFAULT_INSTANCE); } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ @java.lang.Override public java.util.List getTouchesList() { return java.util.Collections.unmodifiableList( instance.getTouchesList()); } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ @java.lang.Override public int getTouchesCount() { return instance.getTouchesCount(); }/** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ @java.lang.Override public com.android.emulator.control.Touch getTouches(int index) { return instance.getTouches(index); } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ public Builder setTouches( int index, com.android.emulator.control.Touch value) { copyOnWrite(); instance.setTouches(index, value); return this; } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ public Builder setTouches( int index, com.android.emulator.control.Touch.Builder builderForValue) { copyOnWrite(); instance.setTouches(index, builderForValue.build()); return this; } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ public Builder addTouches(com.android.emulator.control.Touch value) { copyOnWrite(); instance.addTouches(value); return this; } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ public Builder addTouches( int index, com.android.emulator.control.Touch value) { copyOnWrite(); instance.addTouches(index, value); return this; } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ public Builder addTouches( com.android.emulator.control.Touch.Builder builderForValue) { copyOnWrite(); instance.addTouches(builderForValue.build()); return this; } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ public Builder addTouches( int index, com.android.emulator.control.Touch.Builder builderForValue) { copyOnWrite(); instance.addTouches(index, builderForValue.build()); return this; } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ public Builder addAllTouches( java.lang.Iterable values) { copyOnWrite(); instance.addAllTouches(values); return this; } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ public Builder clearTouches() { copyOnWrite(); instance.clearTouches(); return this; } /** *
     * The list of Touch objects, note that these do not need to be unique
     * 
* * repeated .android.emulation.control.Touch touches = 1; */ public Builder removeTouches(int index) { copyOnWrite(); instance.removeTouches(index); return this; } /** *
     * The display device where the touch event occurred.
     * Omitting or using the value 0 indicates the main display.
     *
     * Touch events cannot be send to devices other than 0, due to
     * https://issuetracker.google.com/issues/150699691
     * 
* * int32 device = 2; * @return The device. */ @java.lang.Override public int getDevice() { return instance.getDevice(); } /** *
     * The display device where the touch event occurred.
     * Omitting or using the value 0 indicates the main display.
     *
     * Touch events cannot be send to devices other than 0, due to
     * https://issuetracker.google.com/issues/150699691
     * 
* * int32 device = 2; * @param value The device to set. * @return This builder for chaining. */ public Builder setDevice(int value) { copyOnWrite(); instance.setDevice(value); return this; } /** *
     * The display device where the touch event occurred.
     * Omitting or using the value 0 indicates the main display.
     *
     * Touch events cannot be send to devices other than 0, due to
     * https://issuetracker.google.com/issues/150699691
     * 
* * int32 device = 2; * @return This builder for chaining. */ public Builder clearDevice() { copyOnWrite(); instance.clearDevice(); return this; } // @@protoc_insertion_point(builder_scope:android.emulation.control.TouchEvent) } @java.lang.Override @java.lang.SuppressWarnings({"unchecked", "fallthrough"}) protected final java.lang.Object dynamicMethod( com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, java.lang.Object arg0, java.lang.Object arg1) { switch (method) { case NEW_MUTABLE_INSTANCE: { return new com.android.emulator.control.TouchEvent(); } case NEW_BUILDER: { return new Builder(); } case BUILD_MESSAGE_INFO: { java.lang.Object[] objects = new java.lang.Object[] { "touches_", com.android.emulator.control.Touch.class, "device_", }; java.lang.String info = "\u0000\u0002\u0000\u0000\u0001\u0002\u0002\u0000\u0001\u0000\u0001\u001b\u0002\u0004" + ""; return newMessageInfo(DEFAULT_INSTANCE, info, objects); } // fall through case GET_DEFAULT_INSTANCE: { return DEFAULT_INSTANCE; } case GET_PARSER: { com.google.protobuf.Parser parser = PARSER; if (parser == null) { synchronized (com.android.emulator.control.TouchEvent.class) { parser = PARSER; if (parser == null) { parser = new DefaultInstanceBasedParser( DEFAULT_INSTANCE); PARSER = parser; } } } return parser; } case GET_MEMOIZED_IS_INITIALIZED: { return (byte) 1; } case SET_MEMOIZED_IS_INITIALIZED: { return null; } } throw new UnsupportedOperationException(); } // @@protoc_insertion_point(class_scope:android.emulation.control.TouchEvent) private static final com.android.emulator.control.TouchEvent DEFAULT_INSTANCE; static { TouchEvent defaultInstance = new TouchEvent(); // New instances are implicitly immutable so no need to make // immutable. DEFAULT_INSTANCE = defaultInstance; com.google.protobuf.GeneratedMessageLite.registerDefaultInstance( TouchEvent.class, defaultInstance); } public static com.android.emulator.control.TouchEvent getDefaultInstance() { return DEFAULT_INSTANCE; } private static volatile com.google.protobuf.Parser PARSER; public static com.google.protobuf.Parser parser() { return DEFAULT_INSTANCE.getParserForType(); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy