00001
00002
00003 package ros.pkg.mapping_msgs.msg;
00004
00005 import java.nio.ByteBuffer;
00006
00007 public class CollisionObjectOperation extends ros.communication.Message {
00008 static public final short ADD = 0;
00009 static public final short REMOVE = 1;
00010 static public final short DETACH_AND_ADD_AS_OBJECT = 2;
00011 static public final short ATTACH_AND_REMOVE_AS_OBJECT = 3;
00012
00013 public short operation;
00014
00015 public CollisionObjectOperation() {
00016 }
00017
00018 public static java.lang.String __s_getDataType() { return "mapping_msgs/CollisionObjectOperation"; }
00019 public java.lang.String getDataType() { return __s_getDataType(); }
00020 public static java.lang.String __s_getMD5Sum() { return "66a2b3b971d193145f8da8c3e401a474"; }
00021 public java.lang.String getMD5Sum() { return __s_getMD5Sum(); }
00022 public static java.lang.String __s_getMessageDefinition() { return "#Puts the object into the environment\n" +
00023 "#or updates the object if already added\n" +
00024 "byte ADD=0\n" +
00025 "\n" +
00026 "#Removes the object from the environment entirely\n" +
00027 "byte REMOVE=1\n" +
00028 "\n" +
00029 "#Only valid within the context of a CollisionAttachedObject message\n" +
00030 "#Will be ignored if sent with an CollisionObject message\n" +
00031 "#Takes an attached object, detaches from the attached link\n" +
00032 "#But adds back in as regular object\n" +
00033 "byte DETACH_AND_ADD_AS_OBJECT=2\n" +
00034 "\n" +
00035 "#Only valid within the context of a CollisionAttachedObject message\n" +
00036 "#Will be ignored if sent with an CollisionObject message\n" +
00037 "#Takes current object in the environment and removes it as\n" +
00038 "#a regular object\n" +
00039 "byte ATTACH_AND_REMOVE_AS_OBJECT=3\n" +
00040 "\n" +
00041 "# Byte code for operation\n" +
00042 "byte operation\n" +
00043 "\n" +
00044 ""; }
00045 public java.lang.String getMessageDefinition() { return __s_getMessageDefinition(); }
00046
00047 public CollisionObjectOperation clone() {
00048 CollisionObjectOperation c = new CollisionObjectOperation();
00049 c.deserialize(serialize(0));
00050 return c;
00051 }
00052
00053 public void setTo(ros.communication.Message m) {
00054 deserialize(m.serialize(0));
00055 }
00056
00057 public int serializationLength() {
00058 int __l = 0;
00059 __l += 1;
00060 return __l;
00061 }
00062
00063 public void serialize(ByteBuffer bb, int seq) {
00064 bb.put((byte)operation);
00065 }
00066
00067 public void deserialize(ByteBuffer bb) {
00068 operation = (short)(bb.get() & 0xff);
00069 }
00070
00071 @SuppressWarnings("all")
00072 public boolean equals(Object o) {
00073 if(!(o instanceof CollisionObjectOperation))
00074 return false;
00075 CollisionObjectOperation other = (CollisionObjectOperation) o;
00076 return
00077 operation == other.operation &&
00078 true;
00079 }
00080
00081 @SuppressWarnings("all")
00082 public int hashCode() {
00083 final int prime = 31;
00084 int result = 1;
00085 long tmp;
00086 result = prime * result + this.operation;
00087 return result;
00088 }
00089 }
00090