CloneSet2135


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
47201.000class_body_declarations[9]
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
147166
plugins/org.eclipse.jdt.debug/jdi/org/eclipse/jdi/internal/jdwp/JdwpCommandPacket.java
247169
plugins/org.eclipse.jdt.debug/jdi/org/eclipse/jdi/internal/spy/JdwpCommandPacket.java
Clone Instance
1
Line Count
47
Source Line
166
Source File
plugins/org.eclipse.jdt.debug/jdi/org/eclipse/jdi/internal/jdwp/JdwpCommandPacket.java

        /** Mapping of command codes to strings. */
        private static Map fgCommandMap = null;

        /** Next id to be assigned. */
        private static int fgNextId = 1;

        /** Command, note that this field is 256 * JDWP CommandSet (unsigned) + JDWP Command. */
        private int fCommand;

        /**
         * Creates new JdwpCommandPacket.
         */
        protected JdwpCommandPacket() {
        }

        /**
         * Creates new JdwpCommandPacket.
         */
        public JdwpCommandPacket(int command) {
                setCommand(command);
                setId(getNewId());
        }

        /**
         * @return Returns unique id for command packet.
         */
        public static synchronized int getNewId() {
                return fgNextId++;
        }

        /**
         * @return Returns JDWP command set of packet.
         */
        public byte getCommandSet() {
                return (byte) (fCommand >>> 8);
        }

        /**
         * @return Returns 256 * JDWP CommandSet (unsigned) + JDWP Command.
         */
        public int getCommand() {
                return fCommand;
        }

        /**
         * Assigns command (256 * JDWP CommandSet (unsigned) + JDWP Command)
         */
        public void setCommand(int command) {
                fCommand = command;
        }


Clone Instance
2
Line Count
47
Source Line
169
Source File
plugins/org.eclipse.jdt.debug/jdi/org/eclipse/jdi/internal/spy/JdwpCommandPacket.java

        /** Mapping of command codes to strings. */
        private static Map fgCommandMap = null;

        /** Next id to be assigned. */
        private static int fgNextId = 1;

        /** Command, note that this field is 256 * JDWP CommandSet (unsigned) + JDWP Command. */
        private int fCommand;

        /**
         * Creates new JdwpCommandPacket.
         */
        protected JdwpCommandPacket() {
        }

        /**
         * Creates new JdwpCommandPacket.
         */
        public JdwpCommandPacket(int command) {
                setCommand(command);
                setId(getNewId());
        }

        /**
         * @return Returns unique id for command packet.
         */
        public static synchronized int getNewId() {
                return fgNextId++;
        }

        /**
         * @return Returns JDWP command set of packet.
         */
        public byte getCommandSet() {
                return (byte) (fCommand >>> 8);
        }

        /**
         * @return Returns 256 * JDWP CommandSet (unsigned) + JDWP Command.
         */
        public int getCommand() {
                return fCommand;
        }

        /**
         * Assigns command (256 * JDWP CommandSet (unsigned) + JDWP Command)
         */
        public void setCommand(int command) {
                fCommand = command;
        }


Clone AbstractionParameter Count: 0Parameter Bindings

/** Mapping of command codes to strings. */
private static Map fgCommandMap = null;

/** Next id to be assigned. */
private static int fgNextId = 1;

/** Command, note that this field is 256 * JDWP CommandSet (unsigned) + JDWP Command. */
private int fCommand;

/**
         * Creates new JdwpCommandPacket.
         */
protected JdwpCommandPacket() {
}

/**
         * Creates new JdwpCommandPacket.
         */
public JdwpCommandPacket(int command) {
  setCommand(command);
  setId(getNewId());
}

/**
         * @return Returns unique id for command packet.
         */
public static synchronized int getNewId() {
  return fgNextId++;
}

/**
         * @return Returns JDWP command set of packet.
         */
public byte getCommandSet() {
  return (byte) (fCommand >>> 8);
}

/**
         * @return Returns 256 * JDWP CommandSet (unsigned) + JDWP Command.
         */
public int getCommand() {
  return fCommand;
}

/**
         * Assigns command (256 * JDWP CommandSet (unsigned) + JDWP Command)
         */
public void setCommand(int command) {
  fCommand = command;
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
None