|
{"question_id": "6367676d1a6d9265ec018229", "input": "/** \n * Trim the elements of the given String array, calling <code>String.trim()</code> on each of them.\n * @param array the original String array\n * @return the resulting array (of the same size) with trimmed elements\n */\n\npublic static String[] trimArrayElements(String[] array){", "signature": "public static String[] trimArrayElements(String[] array){", "docstring": "/** \n * Trim the elements of the given String array, calling <code>String.trim()</code> on each of them.\n * @param array the original String array\n * @return the resulting array (of the same size) with trimmed elements\n */\n"}
|
|
{"question_id": "6367670b1a6d9265ec017a00", "input": "/** \n * <p>Checks whether two arrays are the same length, treating <code>null</code> arrays as length <code>0</code>.</p>\n * @param array1 the first array, may be <code>null</code>\n * @param array2 the second array, may be <code>null</code>\n * @return <code>true</code> if length of arrays matches, treating<code>null</code> as an empty array\n */\n\npublic static boolean isSameLength(final byte[] array1,final byte[] array2){", "signature": "public static boolean isSameLength(final byte[] array1,final byte[] array2){", "docstring": "/** \n * <p>Checks whether two arrays are the same length, treating <code>null</code> arrays as length <code>0</code>.</p>\n * @param array1 the first array, may be <code>null</code>\n * @param array2 the second array, may be <code>null</code>\n * @return <code>true</code> if length of arrays matches, treating<code>null</code> as an empty array\n */\n"}
|
|
{"question_id": "636766a91a6d9265ec0175c2", "input": "/** \n * Pops an abstract type from the output frame stack and returns its value.\n * @return the abstract type that has been popped from the output frame stack.\n */\n\nprivate int pop(){", "signature": "private int pop(){", "docstring": "/** \n * Pops an abstract type from the output frame stack and returns its value.\n * @return the abstract type that has been popped from the output frame stack.\n */\n"}
|
|
{"question_id": "636767081a6d9265ec017989", "input": "/** \n * <p>Converts an array of object Booleans to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Boolean</code> array, may be <code>null</code>\n * @return a <code>boolean</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n\npublic static boolean[] toPrimitive(final Boolean[] array){", "signature": "public static boolean[] toPrimitive(final Boolean[] array){", "docstring": "/** \n * <p>Converts an array of object Booleans to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Boolean</code> array, may be <code>null</code>\n * @return a <code>boolean</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n"}
|
|
{"question_id": "6367672d1a6d9265ec017c73", "input": "/** \n * Returns true if the message should be printed in the given timestamp, otherwise returns false. If this method returns false, the message will not be printed. The timestamp is in seconds granularity. \n */\n\npublic boolean shouldPrintMessage(int timestamp,String message){", "signature": "public boolean shouldPrintMessage(int timestamp,String message){", "docstring": "/** \n * Returns true if the message should be printed in the given timestamp, otherwise returns false. If this method returns false, the message will not be printed. The timestamp is in seconds granularity. \n */\n"}
|
|
{"question_id": "636766f81a6d9265ec01775c", "input": "/** \n * <p>Gets the <code>toString</code> of an <code>Object</code> returning an empty string (\"\") if <code>null</code> input.</p> <pre> ObjectUtils.toString(null) = \"\" ObjectUtils.toString(\"\") = \"\" ObjectUtils.toString(\"bat\") = \"bat\" ObjectUtils.toString(Boolean.TRUE) = \"true\" </pre>\n * @see StringUtils#defaultString(String)\n * @see String#valueOf(Object)\n * @param obj the Object to <code>toString</code>, may be null\n * @return the passed in Object's toString, or nullStr if <code>null</code> input\n * @since 2.0\n */\n\npublic static String toString(Object obj){", "signature": "public static String toString(Object obj){", "docstring": "/** \n * <p>Gets the <code>toString</code> of an <code>Object</code> returning an empty string (\"\") if <code>null</code> input.</p> <pre> ObjectUtils.toString(null) = \"\" ObjectUtils.toString(\"\") = \"\" ObjectUtils.toString(\"bat\") = \"bat\" ObjectUtils.toString(Boolean.TRUE) = \"true\" </pre>\n * @see StringUtils#defaultString(String)\n * @see String#valueOf(Object)\n * @param obj the Object to <code>toString</code>, may be null\n * @return the passed in Object's toString, or nullStr if <code>null</code> input\n * @since 2.0\n */\n"}
|
|
{"question_id": "6367667f1a6d9265ec017457", "input": "/** \n * Decodes octets to characters using the UTF-8 decoding and appends the characters to a StringBuffer.\n * @return the index to the next unchecked character in the string to decode\n */\n\nprivate static int decodeOctets(int i,ByteBuffer bb,StringBuilder sb){", "signature": "private static int decodeOctets(int i,ByteBuffer bb,StringBuilder sb){", "docstring": "/** \n * Decodes octets to characters using the UTF-8 decoding and appends the characters to a StringBuffer.\n * @return the index to the next unchecked character in the string to decode\n */\n"}
|
|
{"question_id": "636766aa1a6d9265ec0175ce", "input": "/** \n * Starts the visit of a new stack map frame, stored in {@link #currentFrame}.\n * @param offset the bytecode offset of the instruction to which the frame corresponds.\n * @param numLocal the number of local variables in the frame.\n * @param numStack the number of stack elements in the frame.\n * @return the index of the next element to be written in this frame.\n */\n\nint visitFrameStart(final int offset,final int numLocal,final int numStack){", "signature": "int visitFrameStart(final int offset,final int numLocal,final int numStack){", "docstring": "/** \n * Starts the visit of a new stack map frame, stored in {@link #currentFrame}.\n * @param offset the bytecode offset of the instruction to which the frame corresponds.\n * @param numLocal the number of local variables in the frame.\n * @param numStack the number of stack elements in the frame.\n * @return the index of the next element to be written in this frame.\n */\n"}
|
|
{"question_id": "636767191a6d9265ec017c0f", "input": "/** \n * Enlarges this byte vector so that it can receive 'size' more bytes.\n * @param size number of additional bytes that this byte vector should be able to receive.\n */\n\nprivate void enlarge(final int size){", "signature": "private void enlarge(final int size){", "docstring": "/** \n * Enlarges this byte vector so that it can receive 'size' more bytes.\n * @param size number of additional bytes that this byte vector should be able to receive.\n */\n"}
|
|
{"question_id": "636767821a6d9265ec0183a0", "input": "/** \n * Delete's the specified file if it exists \n */\n\nprotected static void deleteFile(String fileName){", "signature": "protected static void deleteFile(String fileName){", "docstring": "/** \n * Delete's the specified file if it exists \n */\n"}
|
|
{"question_id": "636767691a6d9265ec0181aa", "input": "/** \n * Return a hash code based on the contents of the specified array. If <code>array</code> is <code>null</code>, this method returns 0.\n * @param array the long array to obtain a hashcode\n * @return the long array's hashcode, which could be 0 if the array is null.\n */\n\npublic static int nullSafeHashCode(long[] array){", "signature": "public static int nullSafeHashCode(long[] array){", "docstring": "/** \n * Return a hash code based on the contents of the specified array. If <code>array</code> is <code>null</code>, this method returns 0.\n * @param array the long array to obtain a hashcode\n * @return the long array's hashcode, which could be 0 if the array is null.\n */\n"}
|
|
{"question_id": "636767441a6d9265ec017cc1", "input": "/** \n * Performs a right node rotation.\n * @param node a node to rotate\n * @return a new parent of the {@code node}\n */\n\nprivate TreeNode<T> rotateRight(TreeNode<T> node){", "signature": "private TreeNode<T> rotateRight(TreeNode<T> node){", "docstring": "/** \n * Performs a right node rotation.\n * @param node a node to rotate\n * @return a new parent of the {@code node}\n */\n"}
|
|
{"question_id": "6367667f1a6d9265ec01745c", "input": "/** \n * Add all the jar files in a dir to the classpath, represented as a Vector of URLs.\n */\n\n@SuppressWarnings(\"unchecked\") public static void addToClassPath(Vector<URL> cpV,String dir){", "signature": "@SuppressWarnings(\"unchecked\") public static void addToClassPath(Vector<URL> cpV,String dir){", "docstring": "/** \n * Add all the jar files in a dir to the classpath, represented as a Vector of URLs.\n */\n"}
|
|
{"question_id": "6367677e1a6d9265ec01830f", "input": "/** \n * Produces a formatted string as specified by the conversion pattern.\n */\n\npublic String format(LoggingEvent event){", "signature": "public String format(LoggingEvent event){", "docstring": "/** \n * Produces a formatted string as specified by the conversion pattern.\n */\n"}
|
|
{"question_id": "636767031a6d9265ec0178dd", "input": "/** \n * Retrieve the content length of the request.\n * @return The content length of the request.\n * @since 1.3\n */\n\npublic long contentLength(){", "signature": "public long contentLength(){", "docstring": "/** \n * Retrieve the content length of the request.\n * @return The content length of the request.\n * @since 1.3\n */\n"}
|
|
{"question_id": "636766f11a6d9265ec017658", "input": "/** \n * Returns the index of the last directory separator character. <p> This method will handle a file in either Unix or Windows format. The position of the last forward or backslash is returned. <p> The output will be the same irrespective of the machine that the code is running on.\n * @param filename the filename to find the last path separator in, null returns -1\n * @return the index of the last separator character, or -1 if thereis no such character\n */\n\npublic static int indexOfLastSeparator(String filename){", "signature": "public static int indexOfLastSeparator(String filename){", "docstring": "/** \n * Returns the index of the last directory separator character. <p> This method will handle a file in either Unix or Windows format. The position of the last forward or backslash is returned. <p> The output will be the same irrespective of the machine that the code is running on.\n * @param filename the filename to find the last path separator in, null returns -1\n * @return the index of the last separator character, or -1 if thereis no such character\n */\n"}
|
|
{"question_id": "636767121a6d9265ec017b0a", "input": "/** \n * Skips bytes until the end of the current line.\n * @param headerPart The headers, which are being parsed.\n * @param end Index of the last byte, which has yet been processed.\n * @return Index of the \\r\\n sequence, which indicates end of line.\n */\n\nprivate int parseEndOfLine(String headerPart,int end){", "signature": "private int parseEndOfLine(String headerPart,int end){", "docstring": "/** \n * Skips bytes until the end of the current line.\n * @param headerPart The headers, which are being parsed.\n * @param end Index of the last byte, which has yet been processed.\n * @return Index of the \\r\\n sequence, which indicates end of line.\n */\n"}
|
|
{"question_id": "636766f61a6d9265ec017701", "input": "/** \n * Finds the last index within a String, handling <code>null</code>. This method uses {@link String#lastIndexOf(String)}. \n */\n\npublic static int lastIndexOf(String str,String searchStr){", "signature": "public static int lastIndexOf(String str,String searchStr){", "docstring": "/** \n * Finds the last index within a String, handling <code>null</code>. This method uses {@link String#lastIndexOf(String)}. \n */\n"}
|
|
{"question_id": "6367670b1a6d9265ec0179fe", "input": "/** \n * Writes <code>b.length</code> bytes from the specified byte array to this output stream.\n * @param b The array of bytes to be written.\n * @exception IOException if an error occurs.\n */\n\n@Override public void write(byte b[]) throws IOException {", "signature": "@Override public void write(byte b[]) throws IOException {", "docstring": "/** \n * Writes <code>b.length</code> bytes from the specified byte array to this output stream.\n * @param b The array of bytes to be written.\n * @exception IOException if an error occurs.\n */\n"}
|
|
{"question_id": "636767df1a6d9265ec01873c", "input": "/** \n * @return the row id\n */\n\npublic String id(String entityId){", "signature": "public String id(String entityId){", "docstring": "/** \n * @return the row id\n */\n"}
|
|
{"question_id": "636766f91a6d9265ec01777f", "input": "/** \n * <p>Converts a Boolean to a boolean handling <code>null</code> by returning <code>false</code>.</p> <pre> BooleanUtils.toBoolean(Boolean.TRUE) = true BooleanUtils.toBoolean(Boolean.FALSE) = false BooleanUtils.toBoolean(null) = false </pre>\n * @param bool the boolean to convert\n * @return <code>true</code> or <code>false</code>, <code>null</code> returns <code>false</code>\n */\n\npublic static boolean toBoolean(Boolean bool){", "signature": "public static boolean toBoolean(Boolean bool){", "docstring": "/** \n * <p>Converts a Boolean to a boolean handling <code>null</code> by returning <code>false</code>.</p> <pre> BooleanUtils.toBoolean(Boolean.TRUE) = true BooleanUtils.toBoolean(Boolean.FALSE) = false BooleanUtils.toBoolean(null) = false </pre>\n * @param bool the boolean to convert\n * @return <code>true</code> or <code>false</code>, <code>null</code> returns <code>false</code>\n */\n"}
|
|
{"question_id": "6367675f1a6d9265ec0180d3", "input": "/** \n * Computes an identity automorphism (i.e. a self-mapping of a graph in which each vertex also maps to itself).\n * @param graph the input graph\n * @param < V > the graph vertex type\n * @param < E > the graph edge type\n * @return a mapping from graph to graph\n */\n\npublic static <V,E>IsomorphicGraphMapping<V,E> identity(Graph<V,E> graph){", "signature": "public static <V,E>IsomorphicGraphMapping<V,E> identity(Graph<V,E> graph){", "docstring": "/** \n * Computes an identity automorphism (i.e. a self-mapping of a graph in which each vertex also maps to itself).\n * @param graph the input graph\n * @param < V > the graph vertex type\n * @param < E > the graph edge type\n * @return a mapping from graph to graph\n */\n"}
|
|
{"question_id": "636766fe1a6d9265ec017833", "input": "/** \n * Schedules a file to be deleted when JVM exits. If file is directory delete it and all sub-directories.\n * @param file file or directory to delete, must not be {@code null}\n * @throws NullPointerException if the file is {@code null}\n * @throws IOException in case deletion is unsuccessful\n */\n\npublic static void forceDeleteOnExit(File file) throws IOException {", "signature": "public static void forceDeleteOnExit(File file) throws IOException {", "docstring": "/** \n * Schedules a file to be deleted when JVM exits. If file is directory delete it and all sub-directories.\n * @param file file or directory to delete, must not be {@code null}\n * @throws NullPointerException if the file is {@code null}\n * @throws IOException in case deletion is unsuccessful\n */\n"}
|
|
{"question_id": "636767791a6d9265ec018257", "input": "/** \n * Add a log record message to be displayed in the LogTable. This method is thread-safe as it posts requests to the SwingThread rather than processing directly.\n */\n\npublic void addMessage(final LogRecord lr){", "signature": "public void addMessage(final LogRecord lr){", "docstring": "/** \n * Add a log record message to be displayed in the LogTable. This method is thread-safe as it posts requests to the SwingThread rather than processing directly.\n */\n"}
|
|
{"question_id": "636767641a6d9265ec01817d", "input": "/** \n * Construct a complete bipartite graph\n */\n\n@Override public void generateGraph(Graph<V,E> target,Map<String,V> resultMap){", "signature": "@Override public void generateGraph(Graph<V,E> target,Map<String,V> resultMap){", "docstring": "/** \n * Construct a complete bipartite graph\n */\n"}
|
|
{"question_id": "636766ff1a6d9265ec017851", "input": "/** \n * Searches for a byte of specified value in the <code>buffer</code>, starting at the specified <code>position</code>.\n * @param value The value to find.\n * @param pos The starting position for searching.\n * @return The position of byte found, counting from beginning of the<code>buffer</code>, or <code>-1</code> if not found.\n */\n\nprotected int findByte(byte value,int pos){", "signature": "protected int findByte(byte value,int pos){", "docstring": "/** \n * Searches for a byte of specified value in the <code>buffer</code>, starting at the specified <code>position</code>.\n * @param value The value to find.\n * @param pos The starting position for searching.\n * @return The position of byte found, counting from beginning of the<code>buffer</code>, or <code>-1</code> if not found.\n */\n"}
|
|
{"question_id": "636767a41a6d9265ec018582", "input": "/** \n * Serializes the {@code message}, prefixed with its length, into an {@link OutputStream}.\n * @return the size of the message\n */\n\npublic static <T>int writeDelimitedTo(OutputStream out,T message,Schema<T> schema,LinkedBuffer buffer) throws IOException {", "signature": "public static <T>int writeDelimitedTo(OutputStream out,T message,Schema<T> schema,LinkedBuffer buffer) throws IOException {", "docstring": "/** \n * Serializes the {@code message}, prefixed with its length, into an {@link OutputStream}.\n * @return the size of the message\n */\n"}
|
|
{"question_id": "636767001a6d9265ec01787e", "input": "/** \n * <p> Gets the String built by this builder. </p>\n * @return the built string\n */\n\npublic String toString(){", "signature": "public String toString(){", "docstring": "/** \n * <p> Gets the String built by this builder. </p>\n * @return the built string\n */\n"}
|
|
{"question_id": "636767781a6d9265ec01823d", "input": "/** \n * This method does actual writing\n */\n\nprotected void subAppend(LoggingEvent event){", "signature": "protected void subAppend(LoggingEvent event){", "docstring": "/** \n * This method does actual writing\n */\n"}
|
|
{"question_id": "636766ef1a6d9265ec01761a", "input": "/** \n * Adds a type in the type table of this symbol table. Does nothing if the type table already contains a similar type.\n * @param value an internal class name.\n * @return the index of a new or already existing type Symbol with the given value.\n */\n\nint addType(final String value){", "signature": "int addType(final String value){", "docstring": "/** \n * Adds a type in the type table of this symbol table. Does nothing if the type table already contains a similar type.\n * @param value an internal class name.\n * @return the index of a new or already existing type Symbol with the given value.\n */\n"}
|
|
{"question_id": "636766821a6d9265ec0174b6", "input": "/** \n * Resolves the arguments for the {@code genericType} using the type variable information for the{@code targetType}. Returns {@code null} if {@code genericType} is not parameterized or ifarguments cannot be resolved.\n */\n\npublic static Class<?>[] resolveArguments(Type genericType,Class<?> targetType){", "signature": "public static Class<?>[] resolveArguments(Type genericType,Class<?> targetType){", "docstring": "/** \n * Resolves the arguments for the {@code genericType} using the type variable information for the{@code targetType}. Returns {@code null} if {@code genericType} is not parameterized or ifarguments cannot be resolved.\n */\n"}
|
|
{"question_id": "636767e11a6d9265ec018781", "input": "/** \n * Accept the data into the cache and merge with the existing value. This method is not thread safe, should avoid concurrency calling.\n * @param data to be added potentially.\n */\n\n@Override public void accept(final METRICS data){", "signature": "@Override public void accept(final METRICS data){", "docstring": "/** \n * Accept the data into the cache and merge with the existing value. This method is not thread safe, should avoid concurrency calling.\n * @param data to be added potentially.\n */\n"}
|
|
{"question_id": "636767531a6d9265ec017efb", "input": "/** \n * Inserts this bucket in the data structure before the {@code bucket}.\n * @param bucket the bucket, that will be the next to this bucket.\n */\n\nvoid insertBefore(Bucket bucket){", "signature": "void insertBefore(Bucket bucket){", "docstring": "/** \n * Inserts this bucket in the data structure before the {@code bucket}.\n * @param bucket the bucket, that will be the next to this bucket.\n */\n"}
|
|
{"question_id": "636766f11a6d9265ec017641", "input": "/** \n * @see InputStream#available() \n */\n\n@Override public int available() throws IOException {", "signature": "@Override public int available() throws IOException {", "docstring": "/** \n * @see InputStream#available() \n */\n"}
|
|
{"question_id": "636767de1a6d9265ec018706", "input": "/** \n * Returns mappings with fields that not exist in the input mappings. The input mappings should be history mapping from current index. Do not return _source config to avoid current index update conflict.\n */\n\npublic Mappings diffStructure(String tableName,Mappings mappings){", "signature": "public Mappings diffStructure(String tableName,Mappings mappings){", "docstring": "/** \n * Returns mappings with fields that not exist in the input mappings. The input mappings should be history mapping from current index. Do not return _source config to avoid current index update conflict.\n */\n"}
|
|
{"question_id": "636767dd1a6d9265ec0186e5", "input": "/** \n * Add a new target channels.\n */\n\npublic void addNewTarget(Channels channels,IConsumer consumer){", "signature": "public void addNewTarget(Channels channels,IConsumer consumer){", "docstring": "/** \n * Add a new target channels.\n */\n"}
|
|
{"question_id": "636767871a6d9265ec01846d", "input": "/** \n * Creates the directory where the MRU file list will be written. The \"lf5\" directory is created in the Documents and Settings directory on Windows 2000 machines and where ever the user.home variable points on all other platforms.\n */\n\npublic static void createConfigurationDirectory(){", "signature": "public static void createConfigurationDirectory(){", "docstring": "/** \n * Creates the directory where the MRU file list will be written. The \"lf5\" directory is created in the Documents and Settings directory on Windows 2000 machines and where ever the user.home variable points on all other platforms.\n */\n"}
|
|
{"question_id": "636766f81a6d9265ec01775b", "input": "/** \n * Reads a signed long value in this {@link ClassReader}. <i>This method is intended for {@link Attribute} sub classes, and is normally not needed by class generators or adapters.</i>\n * @param offset the start offset of the value to be read in this {@link ClassReader}.\n * @return the read value.\n */\n\npublic long readLong(final int offset){", "signature": "public long readLong(final int offset){", "docstring": "/** \n * Reads a signed long value in this {@link ClassReader}. <i>This method is intended for {@link Attribute} sub classes, and is normally not needed by class generators or adapters.</i>\n * @param offset the start offset of the value to be read in this {@link ClassReader}.\n * @return the read value.\n */\n"}
|
|
{"question_id": "636767a51a6d9265ec01859d", "input": "/** \n * Returns true if the contents of the internal array and the provided array match.\n */\n\npublic boolean equals(final byte[] data,int offset,final int len){", "signature": "public boolean equals(final byte[] data,int offset,final int len){", "docstring": "/** \n * Returns true if the contents of the internal array and the provided array match.\n */\n"}
|
|
{"question_id": "6367670b1a6d9265ec0179ff", "input": "/** \n * <p>Defensive programming technique to change a <code>null</code> reference to an empty one.</p> <p>This method returns an empty array for a <code>null</code> input array.</p> <p>As a memory optimizing technique an empty array passed in will be overridden with the empty <code>public static</code> references in this class.</p>\n * @param array the array to check for <code>null</code> or empty\n * @return the same array, <code>public static</code> empty array if <code>null</code> or empty input\n * @since 2.5\n */\n\npublic static Byte[] nullToEmpty(final Byte[] array){", "signature": "public static Byte[] nullToEmpty(final Byte[] array){", "docstring": "/** \n * <p>Defensive programming technique to change a <code>null</code> reference to an empty one.</p> <p>This method returns an empty array for a <code>null</code> input array.</p> <p>As a memory optimizing technique an empty array passed in will be overridden with the empty <code>public static</code> references in this class.</p>\n * @param array the array to check for <code>null</code> or empty\n * @return the same array, <code>public static</code> empty array if <code>null</code> or empty input\n * @since 2.5\n */\n"}
|
|
{"question_id": "6367677f1a6d9265ec018347", "input": "/** \n * sends a message to each of the clients in telnet-friendly output. \n */\n\npublic synchronized void send(final String message){", "signature": "public synchronized void send(final String message){", "docstring": "/** \n * sends a message to each of the clients in telnet-friendly output. \n */\n"}
|
|
{"question_id": "6367670a1a6d9265ec0179e8", "input": "/** \n * <p>Defensive programming technique to change a <code>null</code> reference to an empty one.</p> <p>This method returns an empty array for a <code>null</code> input array.</p> <p>As a memory optimizing technique an empty array passed in will be overridden with the empty <code>public static</code> references in this class.</p>\n * @param array the array to check for <code>null</code> or empty\n * @return the same array, <code>public static</code> empty array if <code>null</code> or empty input\n * @since 2.5\n */\n\npublic static Boolean[] nullToEmpty(final Boolean[] array){", "signature": "public static Boolean[] nullToEmpty(final Boolean[] array){", "docstring": "/** \n * <p>Defensive programming technique to change a <code>null</code> reference to an empty one.</p> <p>This method returns an empty array for a <code>null</code> input array.</p> <p>As a memory optimizing technique an empty array passed in will be overridden with the empty <code>public static</code> references in this class.</p>\n * @param array the array to check for <code>null</code> or empty\n * @return the same array, <code>public static</code> empty array if <code>null</code> or empty input\n * @since 2.5\n */\n"}
|
|
{"question_id": "6367677f1a6d9265ec01834b", "input": "/** \n * Place a {@link LoggingEvent} in the buffer. If the buffer is fullthen the event is <b>silently dropped</b>. It is the caller's responsability to make sure that the buffer has free space. \n */\n\npublic void put(LoggingEvent o){", "signature": "public void put(LoggingEvent o){", "docstring": "/** \n * Place a {@link LoggingEvent} in the buffer. If the buffer is fullthen the event is <b>silently dropped</b>. It is the caller's responsability to make sure that the buffer has free space. \n */\n"}
|
|
{"question_id": "636767df1a6d9265ec018744", "input": "/** \n * Split time ranges to insure the start time and end time is small then {@link #FETCH_DATA_DURATION}\n */\n\nprotected List<TimeRange> buildTimeRanges(long start,long end){", "signature": "protected List<TimeRange> buildTimeRanges(long start,long end){", "docstring": "/** \n * Split time ranges to insure the start time and end time is small then {@link #FETCH_DATA_DURATION}\n */\n"}
|
|
{"question_id": "636767031a6d9265ec0178e6", "input": "/** \n * <p>Converts an array of object Bytes to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Byte</code> array, may be <code>null</code>\n * @return a <code>byte</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n\npublic static byte[] toPrimitive(final Byte[] array){", "signature": "public static byte[] toPrimitive(final Byte[] array){", "docstring": "/** \n * <p>Converts an array of object Bytes to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Byte</code> array, may be <code>null</code>\n * @return a <code>byte</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n"}
|
|
{"question_id": "636767dc1a6d9265ec0186be", "input": "/** \n * Follow the dayStep to re-format the time bucket literal long value. Such as, in dayStep == 11, 20000105 re-formatted time bucket is 20000101, 20000115 re-formatted time bucket is 20000112, 20000123 re-formatted time bucket is 20000123\n */\n\nstatic long compressTimeBucket(long timeBucket,int dayStep){", "signature": "static long compressTimeBucket(long timeBucket,int dayStep){", "docstring": "/** \n * Follow the dayStep to re-format the time bucket literal long value. Such as, in dayStep == 11, 20000105 re-formatted time bucket is 20000101, 20000115 re-formatted time bucket is 20000112, 20000123 re-formatted time bucket is 20000123\n */\n"}
|
|
{"question_id": "636767a41a6d9265ec01856c", "input": "/** \n * Computes the size of the utf8 string beginning at the specified {@code index} with the specified {@code length}.\n */\n\npublic static int computeUTF8Size(final CharSequence str,final int index,final int len){", "signature": "public static int computeUTF8Size(final CharSequence str,final int index,final int len){", "docstring": "/** \n * Computes the size of the utf8 string beginning at the specified {@code index} with the specified {@code length}.\n */\n"}
|
|
{"question_id": "636766f01a6d9265ec017639", "input": "/** \n * Array to List. <p> Works like {@link Arrays#asList(Object)}, but handles null arrays.\n * @return a list backed by the array.\n */\n\npublic static <T>List<T> asList(T[] a){", "signature": "public static <T>List<T> asList(T[] a){", "docstring": "/** \n * Array to List. <p> Works like {@link Arrays#asList(Object)}, but handles null arrays.\n * @return a list backed by the array.\n */\n"}
|
|
{"question_id": "6367672d1a6d9265ec017c74", "input": "/** \n * Removes a value from the set. Returns true if the set contained the specified element. \n */\n\npublic boolean remove(int val){", "signature": "public boolean remove(int val){", "docstring": "/** \n * Removes a value from the set. Returns true if the set contained the specified element. \n */\n"}
|
|
{"question_id": "6367676b1a6d9265ec0181df", "input": "/** \n * Returns {@code true} if the given string starts with the specified case-insensitive prefix, {@code false} otherwise.\n * @param str the String to check\n * @param prefix the prefix to look for\n * @return {@code true} if the given string starts with the specified case-insensitive prefix, {@code false} otherwise.\n * @see java.lang.String#startsWith\n */\n\npublic static boolean startsWithIgnoreCase(String str,String prefix){", "signature": "public static boolean startsWithIgnoreCase(String str,String prefix){", "docstring": "/** \n * Returns {@code true} if the given string starts with the specified case-insensitive prefix, {@code false} otherwise.\n * @param str the String to check\n * @param prefix the prefix to look for\n * @return {@code true} if the given string starts with the specified case-insensitive prefix, {@code false} otherwise.\n * @see java.lang.String#startsWith\n */\n"}
|
|
{"question_id": "6367674b1a6d9265ec017dc0", "input": "/** \n * Compute all vertices that have positive degree by iterating over the edges on purpose. This keeps the complexity to $O(m)$ where $m$ is the number of edges.\n * @return set of vertices with positive degree\n */\n\nprivate Set<V> initVisibleVertices(){", "signature": "private Set<V> initVisibleVertices(){", "docstring": "/** \n * Compute all vertices that have positive degree by iterating over the edges on purpose. This keeps the complexity to $O(m)$ where $m$ is the number of edges.\n * @return set of vertices with positive degree\n */\n"}
|
|
{"question_id": "636767001a6d9265ec017873", "input": "/** \n * <p>Reverses a String as per {@link StringBuilder#reverse()}.</p> <p>A <code>null</code> String returns <code>null</code>.</p> <pre> StringUtils.reverse(null) = null StringUtils.reverse(\"\") = \"\" StringUtils.reverse(\"bat\") = \"tab\" </pre>\n * @param str the String to reverse, may be null\n * @return the reversed String, <code>null</code> if null String input\n */\n\npublic static String reverse(final String str){", "signature": "public static String reverse(final String str){", "docstring": "/** \n * <p>Reverses a String as per {@link StringBuilder#reverse()}.</p> <p>A <code>null</code> String returns <code>null</code>.</p> <pre> StringUtils.reverse(null) = null StringUtils.reverse(\"\") = \"\" StringUtils.reverse(\"bat\") = \"tab\" </pre>\n * @param str the String to reverse, may be null\n * @return the reversed String, <code>null</code> if null String input\n */\n"}
|
|
{"question_id": "636766ff1a6d9265ec01783b", "input": "/** \n * Gets a substring from the specified String avoiding exceptions. \n */\n\npublic static String sub(String str,int start,int end){", "signature": "public static String sub(String str,int start,int end){", "docstring": "/** \n * Gets a substring from the specified String avoiding exceptions. \n */\n"}
|
|
{"question_id": "6367671a1a6d9265ec017c15", "input": "/** \n * Puts an array of bytes into this byte vector. The byte vector is automatically enlarged if necessary.\n * @param byteArrayValue an array of bytes. May be {@literal null} to put {@code byteLength} nullbytes into this byte vector.\n * @param byteOffset index of the first byte of byteArrayValue that must be copied.\n * @param byteLength number of bytes of byteArrayValue that must be copied.\n * @return this byte vector.\n */\n\npublic ByteVector putByteArray(final byte[] byteArrayValue,final int byteOffset,final int byteLength){", "signature": "public ByteVector putByteArray(final byte[] byteArrayValue,final int byteOffset,final int byteLength){", "docstring": "/** \n * Puts an array of bytes into this byte vector. The byte vector is automatically enlarged if necessary.\n * @param byteArrayValue an array of bytes. May be {@literal null} to put {@code byteLength} nullbytes into this byte vector.\n * @param byteOffset index of the first byte of byteArrayValue that must be copied.\n * @param byteLength number of bytes of byteArrayValue that must be copied.\n * @return this byte vector.\n */\n"}
|
|
{"question_id": "636766821a6d9265ec0174d2", "input": "/** \n * Wrap an {@link HttpServletRequest}.\n * @param request {@link HttpServletRequest}\n * @return an {@link AtmosphereRequest}\n */\n\npublic static AtmosphereRequest wrap(HttpServletRequest request){", "signature": "public static AtmosphereRequest wrap(HttpServletRequest request){", "docstring": "/** \n * Wrap an {@link HttpServletRequest}.\n * @param request {@link HttpServletRequest}\n * @return an {@link AtmosphereRequest}\n */\n"}
|
|
{"question_id": "636767ab1a6d9265ec01867b", "input": "/** \n * Writes the utf8-encoded bytes from the string into the {@link LinkedBuffer}.\n */\n\npublic static LinkedBuffer writeUTF8(final CharSequence str,final WriteSession session,final LinkedBuffer lb){", "signature": "public static LinkedBuffer writeUTF8(final CharSequence str,final WriteSession session,final LinkedBuffer lb){", "docstring": "/** \n * Writes the utf8-encoded bytes from the string into the {@link LinkedBuffer}.\n */\n"}
|
|
{"question_id": "6367675c1a6d9265ec01805b", "input": "/** \n * Removes this edge from both doubly linked lists of tree edges.\n */\n\npublic void removeFromTreeEdgeList(){", "signature": "public void removeFromTreeEdgeList(){", "docstring": "/** \n * Removes this edge from both doubly linked lists of tree edges.\n */\n"}
|
|
{"question_id": "636767791a6d9265ec01826d", "input": "/** \n * Find the value corresponding to <code>key</code> in <code>props</code>. Then perform variable substitution on the found value.\n */\n\npublic static String findAndSubst(String key,Properties props){", "signature": "public static String findAndSubst(String key,Properties props){", "docstring": "/** \n * Find the value corresponding to <code>key</code> in <code>props</code>. Then perform variable substitution on the found value.\n */\n"}
|
|
{"question_id": "636767001a6d9265ec01787f", "input": "/** \n * <p>Append to the <code>toString</code> the detail of an <code>int</code> array.</p>\n * @param buffer the <code>StringBuffer</code> to populate\n * @param fieldName the field name, typically not used as already appended\n * @param array the array to add to the <code>toString</code>,not <code>null</code>\n */\n\nprotected void appendDetail(StringBuffer buffer,String fieldName,int[] array){", "signature": "protected void appendDetail(StringBuffer buffer,String fieldName,int[] array){", "docstring": "/** \n * <p>Append to the <code>toString</code> the detail of an <code>int</code> array.</p>\n * @param buffer the <code>StringBuffer</code> to populate\n * @param fieldName the field name, typically not used as already appended\n * @param array the array to add to the <code>toString</code>,not <code>null</code>\n */\n"}
|
|
{"question_id": "636766fe1a6d9265ec017834", "input": "/** \n * Session ID. \n */\n\npublic static String sessionId(){", "signature": "public static String sessionId(){", "docstring": "/** \n * Session ID. \n */\n"}
|
|
{"question_id": "636766ff1a6d9265ec01784b", "input": "/** \n * <p>Checks whether the <code>String</code> contains only digit characters.</p> <p><code>Null</code> and empty String will return <code>false</code>.</p>\n * @param str the <code>String</code> to check\n * @return <code>true</code> if str contains only unicode numeric\n */\n\npublic static boolean isDigits(String str){", "signature": "public static boolean isDigits(String str){", "docstring": "/** \n * <p>Checks whether the <code>String</code> contains only digit characters.</p> <p><code>Null</code> and empty String will return <code>false</code>.</p>\n * @param str the <code>String</code> to check\n * @return <code>true</code> if str contains only unicode numeric\n */\n"}
|
|
{"question_id": "636766fc1a6d9265ec0177da", "input": "/** \n * Determine whether a parameter name ends at the current position, that is, whether the given character qualifies as a separator. \n */\n\nprivate static boolean isParameterSeparator(final char c){", "signature": "private static boolean isParameterSeparator(final char c){", "docstring": "/** \n * Determine whether a parameter name ends at the current position, that is, whether the given character qualifies as a separator. \n */\n"}
|
|
{"question_id": "6367670c1a6d9265ec017a35", "input": "/** \n * <p>Check if a String ends with a specified suffix (optionally case insensitive).</p>\n * @see String#endsWith(String)\n * @param str the String to check, may be null\n * @param suffix the suffix to find, may be null\n * @param ignoreCase inidicates whether the compare should ignore case(case insensitive) or not.\n * @return <code>true</code> if the String starts with the prefix orboth <code>null</code>\n */\n\nprivate static boolean endsWith(final String str,final String suffix,final boolean ignoreCase){", "signature": "private static boolean endsWith(final String str,final String suffix,final boolean ignoreCase){", "docstring": "/** \n * <p>Check if a String ends with a specified suffix (optionally case insensitive).</p>\n * @see String#endsWith(String)\n * @param str the String to check, may be null\n * @param suffix the suffix to find, may be null\n * @param ignoreCase inidicates whether the compare should ignore case(case insensitive) or not.\n * @return <code>true</code> if the String starts with the prefix orboth <code>null</code>\n */\n"}
|
|
{"question_id": "6367667f1a6d9265ec01745d", "input": "/** \n * Decode the path component of a URI as path segments.\n * @param u the URI. If the path component is an absolute path componentthen the leading '/' is ignored and is not considered a delimiator of a path segment.\n * @param decode true if the path segments of the path componentshould be in decoded form.\n * @return the list of path segments.\n */\n\npublic static List<PathSegmentImpl> decodePath(URI u,boolean decode){", "signature": "public static List<PathSegmentImpl> decodePath(URI u,boolean decode){", "docstring": "/** \n * Decode the path component of a URI as path segments.\n * @param u the URI. If the path component is an absolute path componentthen the leading '/' is ignored and is not considered a delimiator of a path segment.\n * @param decode true if the path segments of the path componentshould be in decoded form.\n * @return the list of path segments.\n */\n"}
|
|
{"question_id": "636766f11a6d9265ec017651", "input": "/** \n * <p>Defensive programming technique to change a <code>null</code> reference to an empty one.</p> <p>This method returns an empty array for a <code>null</code> input array.</p> <p>As a memory optimizing technique an empty array passed in will be overridden with the empty <code>public static</code> references in this class.</p>\n * @param array the array to check for <code>null</code> or empty\n * @return the same array, <code>public static</code> empty array if <code>null</code> or empty input\n * @since 2.5\n */\n\npublic static Character[] nullToEmpty(final Character[] array){", "signature": "public static Character[] nullToEmpty(final Character[] array){", "docstring": "/** \n * <p>Defensive programming technique to change a <code>null</code> reference to an empty one.</p> <p>This method returns an empty array for a <code>null</code> input array.</p> <p>As a memory optimizing technique an empty array passed in will be overridden with the empty <code>public static</code> references in this class.</p>\n * @param array the array to check for <code>null</code> or empty\n * @return the same array, <code>public static</code> empty array if <code>null</code> or empty input\n * @since 2.5\n */\n"}
|
|
{"question_id": "636767821a6d9265ec0183ab", "input": "/** \n * @return true if getThrown().toString() is a non-empty string.\n */\n\npublic boolean hasThrown(){", "signature": "public boolean hasThrown(){", "docstring": "/** \n * @return true if getThrown().toString() is a non-empty string.\n */\n"}
|
|
{"question_id": "636767831a6d9265ec0183c9", "input": "/** \n * Looks at the last diagnostic context at the top of this NDC without removing it. <p>The returned value is the value that was pushed last. If no context is available, then the empty string \"\" is returned.\n * @return String The innermost diagnostic context.\n */\n\npublic static String peek(){", "signature": "public static String peek(){", "docstring": "/** \n * Looks at the last diagnostic context at the top of this NDC without removing it. <p>The returned value is the value that was pushed last. If no context is available, then the empty string \"\" is returned.\n * @return String The innermost diagnostic context.\n */\n"}
|
|
{"question_id": "636767de1a6d9265ec01871c", "input": "/** \n * Accumulate the value with existing value in the same given key.\n */\n\npublic void valueAccumulation(String key,Long value){", "signature": "public void valueAccumulation(String key,Long value){", "docstring": "/** \n * Accumulate the value with existing value in the same given key.\n */\n"}
|
|
{"question_id": "636766811a6d9265ec017496", "input": "/** \n * Return the next {@link java.io.File} object or {@code null} if no more files areavailable.\n */\n\npublic InputStream next() throws IOException {", "signature": "public InputStream next() throws IOException {", "docstring": "/** \n * Return the next {@link java.io.File} object or {@code null} if no more files areavailable.\n */\n"}
|
|
{"question_id": "6367677e1a6d9265ec01832e", "input": "/** \n * Check if the named logger exists in the hierarchy. If so return its reference, otherwise returns <code>null</code>.\n * @param name The name of the logger to search for.\n */\n\npublic Logger exists(String name){", "signature": "public Logger exists(String name){", "docstring": "/** \n * Check if the named logger exists in the hierarchy. If so return its reference, otherwise returns <code>null</code>.\n * @param name The name of the logger to search for.\n */\n"}
|
|
{"question_id": "6367670a1a6d9265ec0179e7", "input": "/** \n * Look up and return any registered {@link Converter} for the specifieddestination class; if there is no registered Converter, return <code>null</code>.\n * @param clazz Class for which to return a registered Converter\n * @return The registered {@link Converter} or <code>null</code> if not found\n */\n\npublic Converter lookup(final Class<?> clazz){", "signature": "public Converter lookup(final Class<?> clazz){", "docstring": "/** \n * Look up and return any registered {@link Converter} for the specifieddestination class; if there is no registered Converter, return <code>null</code>.\n * @param clazz Class for which to return a registered Converter\n * @return The registered {@link Converter} or <code>null</code> if not found\n */\n"}
|
|
{"question_id": "636767a41a6d9265ec018572", "input": "/** \n * Read a raw Varint from the stream.\n */\n\npublic long readRawVarint64() throws IOException {", "signature": "public long readRawVarint64() throws IOException {", "docstring": "/** \n * Read a raw Varint from the stream.\n */\n"}
|
|
{"question_id": "636767021a6d9265ec0178bb", "input": "/** \n * <p>Defensive programming technique to change a <code>null</code> reference to an empty one.</p> <p>This method returns an empty array for a <code>null</code> input array.</p> <p>As a memory optimizing technique an empty array passed in will be overridden with the empty <code>public static</code> references in this class.</p>\n * @param array the array to check for <code>null</code> or empty\n * @return the same array, <code>public static</code> empty array if <code>null</code> or empty input\n * @since 2.5\n */\n\npublic static Double[] nullToEmpty(final Double[] array){", "signature": "public static Double[] nullToEmpty(final Double[] array){", "docstring": "/** \n * <p>Defensive programming technique to change a <code>null</code> reference to an empty one.</p> <p>This method returns an empty array for a <code>null</code> input array.</p> <p>As a memory optimizing technique an empty array passed in will be overridden with the empty <code>public static</code> references in this class.</p>\n * @param array the array to check for <code>null</code> or empty\n * @return the same array, <code>public static</code> empty array if <code>null</code> or empty input\n * @since 2.5\n */\n"}
|
|
{"question_id": "636767021a6d9265ec0178b2", "input": "/** \n * Pops as many abstract types from the output frame stack as described by the given descriptor.\n * @param descriptor a type or method descriptor (in which case its argument types are popped).\n */\n\nprivate void pop(final String descriptor){", "signature": "private void pop(final String descriptor){", "docstring": "/** \n * Pops as many abstract types from the output frame stack as described by the given descriptor.\n * @param descriptor a type or method descriptor (in which case its argument types are popped).\n */\n"}
|
|
{"question_id": "636766f91a6d9265ec01776e", "input": "/** \n * Writes <code>len</code> bytes from the specified byte array starting at offset <code>off</code> to this byte array output stream.\n * @param b the data.\n * @param off the start offset in the data.\n * @param len the number of bytes to write.\n */\n\n@Override public void write(final byte b[],final int off,final int len) throws IOException {", "signature": "@Override public void write(final byte b[],final int off,final int len) throws IOException {", "docstring": "/** \n * Writes <code>len</code> bytes from the specified byte array starting at offset <code>off</code> to this byte array output stream.\n * @param b the data.\n * @param off the start offset in the data.\n * @param len the number of bytes to write.\n */\n"}
|
|
{"question_id": "636767551a6d9265ec017f3f", "input": "/** \n * Swaps the two elements at the specified indices in the given array.\n * @param < V > the type of elements in the array\n * @param arr the array\n * @param i the index of the first element\n * @param j the index of the second element\n */\n\npublic static final <V>void swap(V[] arr,int i,int j){", "signature": "public static final <V>void swap(V[] arr,int i,int j){", "docstring": "/** \n * Swaps the two elements at the specified indices in the given array.\n * @param < V > the type of elements in the array\n * @param arr the array\n * @param i the index of the first element\n * @param j the index of the second element\n */\n"}
|
|
{"question_id": "636766ae1a6d9265ec0175dc", "input": "/** \n * Check if the actual response is a Partial Content (HTTP 206 code)\n * @return is partial content or not\n */\n\npublic Boolean isPartialContentResponse(){", "signature": "public Boolean isPartialContentResponse(){", "docstring": "/** \n * Check if the actual response is a Partial Content (HTTP 206 code)\n * @return is partial content or not\n */\n"}
|
|
{"question_id": "636766f01a6d9265ec01762e", "input": "/** \n * <p>Checks if an array of primitive doubles is empty or <code>null</code>.</p>\n * @param array the array to test\n * @return <code>true</code> if the array is empty or <code>null</code>\n * @since 2.1\n */\n\npublic static boolean isEmpty(final double[] array){", "signature": "public static boolean isEmpty(final double[] array){", "docstring": "/** \n * <p>Checks if an array of primitive doubles is empty or <code>null</code>.</p>\n * @param array the array to test\n * @return <code>true</code> if the array is empty or <code>null</code>\n * @since 2.1\n */\n"}
|
|
{"question_id": "6367667e1a6d9265ec01743a", "input": "/** \n * The last time, in milliseconds, a write operation occurred.\n * @return this\n */\n\npublic long lastWriteTimeStampInMilliseconds(){", "signature": "public long lastWriteTimeStampInMilliseconds(){", "docstring": "/** \n * The last time, in milliseconds, a write operation occurred.\n * @return this\n */\n"}
|
|
{"question_id": "636767601a6d9265ec0180fd", "input": "/** \n * Add an edge to the index.\n * @param sourceVertex the source vertex\n * @param targetVertex the target vertex\n * @param e the edge\n */\n\nprotected void addToIndex(V sourceVertex,V targetVertex,E e){", "signature": "protected void addToIndex(V sourceVertex,V targetVertex,E e){", "docstring": "/** \n * Add an edge to the index.\n * @param sourceVertex the source vertex\n * @param targetVertex the target vertex\n * @param e the edge\n */\n"}
|
|
{"question_id": "636766821a6d9265ec0174c9", "input": "/** \n * Returns the class path of the current JVM instance as an array of {@link File} objects.\n */\n\nprivate static File[] classPath(){", "signature": "private static File[] classPath(){", "docstring": "/** \n * Returns the class path of the current JVM instance as an array of {@link File} objects.\n */\n"}
|
|
{"question_id": "636767041a6d9265ec0178f8", "input": "/** \n * This method creates a copy of the provided array, and ensures that all the strings in the newly created array contain only lower-case letters. <p> Using this method to copy string arrays means that changes to the src array do not modify the dst array.\n */\n\nprivate static String[] copyStrings(final String[] src){", "signature": "private static String[] copyStrings(final String[] src){", "docstring": "/** \n * This method creates a copy of the provided array, and ensures that all the strings in the newly created array contain only lower-case letters. <p> Using this method to copy string arrays means that changes to the src array do not modify the dst array.\n */\n"}
|
|
{"question_id": "636767521a6d9265ec017ecc", "input": "/** \n * Split a box along the x axis into two equal boxes.\n * @param box the box to split\n * @return a pair with the two resulting boxes\n */\n\npublic static Pair<Box2D,Box2D> splitAlongXAxis(Box2D box){", "signature": "public static Pair<Box2D,Box2D> splitAlongXAxis(Box2D box){", "docstring": "/** \n * Split a box along the x axis into two equal boxes.\n * @param box the box to split\n * @return a pair with the two resulting boxes\n */\n"}
|
|
{"question_id": "636766a91a6d9265ec0175c1", "input": "/** \n * Enlarges this byte vector so that it can receive 'size' more bytes.\n * @param size number of additional bytes that this byte vector should be able to receive.\n */\n\nprivate void enlarge(final int size){", "signature": "private void enlarge(final int size){", "docstring": "/** \n * Enlarges this byte vector so that it can receive 'size' more bytes.\n * @param size number of additional bytes that this byte vector should be able to receive.\n */\n"}
|
|
{"question_id": "636767781a6d9265ec018238", "input": "/** \n * Returns <code>true</code> if the specified appender is in the list of attached appenders, <code>false</code> otherwise.\n * @since 1.2 \n */\n\npublic boolean isAttached(Appender appender){", "signature": "public boolean isAttached(Appender appender){", "docstring": "/** \n * Returns <code>true</code> if the specified appender is in the list of attached appenders, <code>false</code> otherwise.\n * @since 1.2 \n */\n"}
|
|
{"question_id": "6367674a1a6d9265ec017dab", "input": "/** \n * Compares two floating point values. Returns 0 if they are equal, -1 if {@literal o1 < o2}, 1 otherwise\n * @param o1 the first value\n * @param o2 the second value\n * @return 0 if they are equal, -1 if {@literal o1 < o2}, 1 otherwise\n */\n\n@Override public int compare(Double o1,Double o2){", "signature": "@Override public int compare(Double o1,Double o2){", "docstring": "/** \n * Compares two floating point values. Returns 0 if they are equal, -1 if {@literal o1 < o2}, 1 otherwise\n * @param o1 the first value\n * @param o2 the second value\n * @return 0 if they are equal, -1 if {@literal o1 < o2}, 1 otherwise\n */\n"}
|
|
{"question_id": "6367672d1a6d9265ec017c78", "input": "/** \n * Inserts a value to the set. Returns true if the set did not already contain the specified element. \n */\n\npublic boolean insert(int val){", "signature": "public boolean insert(int val){", "docstring": "/** \n * Inserts a value to the set. Returns true if the set did not already contain the specified element. \n */\n"}
|
|
{"question_id": "636767dc1a6d9265ec0186c6", "input": "/** \n * Returns ture when the input fields have already been stored in the properties.\n */\n\nprivate boolean containsAllFields(Fields fields){", "signature": "private boolean containsAllFields(Fields fields){", "docstring": "/** \n * Returns ture when the input fields have already been stored in the properties.\n */\n"}
|
|
{"question_id": "636766821a6d9265ec0174bf", "input": "/** \n * Reverse of Introspector.decapitalize\n */\n\npublic static String capitalize(String name){", "signature": "public static String capitalize(String name){", "docstring": "/** \n * Reverse of Introspector.decapitalize\n */\n"}
|
|
{"question_id": "636767aa1a6d9265ec01865a", "input": "/** \n * Writes the contents of the {@link LinkedBuffer} into the {@link DataOutput}.\n * @return the total content size of the buffer.\n */\n\npublic static int writeTo(final DataOutput out,LinkedBuffer node) throws IOException {", "signature": "public static int writeTo(final DataOutput out,LinkedBuffer node) throws IOException {", "docstring": "/** \n * Writes the contents of the {@link LinkedBuffer} into the {@link DataOutput}.\n * @return the total content size of the buffer.\n */\n"}
|
|
{"question_id": "636766f21a6d9265ec017677", "input": "/** \n * <p>Checks if a <code>Boolean</code> value is <i>not</i> <code>true</code>, handling <code>null</code> by returning <code>true</code>.</p> <pre> BooleanUtils.isNotTrue(Boolean.TRUE) = false BooleanUtils.isNotTrue(Boolean.FALSE) = true BooleanUtils.isNotTrue(null) = true </pre>\n * @param bool the boolean to check, null returns <code>true</code>\n * @return <code>true</code> if the input is null or false\n * @since 2.3\n */\n\npublic static boolean isNotTrue(Boolean bool){", "signature": "public static boolean isNotTrue(Boolean bool){", "docstring": "/** \n * <p>Checks if a <code>Boolean</code> value is <i>not</i> <code>true</code>, handling <code>null</code> by returning <code>true</code>.</p> <pre> BooleanUtils.isNotTrue(Boolean.TRUE) = false BooleanUtils.isNotTrue(Boolean.FALSE) = true BooleanUtils.isNotTrue(null) = true </pre>\n * @param bool the boolean to check, null returns <code>true</code>\n * @return <code>true</code> if the input is null or false\n * @since 2.3\n */\n"}
|
|
{"question_id": "6367674f1a6d9265ec017e74", "input": "/** \n * Returns a textual representation of the queue.\n * @return a textual representation of the queue.\n */\n\npublic String toString(){", "signature": "public String toString(){", "docstring": "/** \n * Returns a textual representation of the queue.\n * @return a textual representation of the queue.\n */\n"}
|
|
{"question_id": "6367675c1a6d9265ec018058", "input": "/** \n * Create a string supplier which returns unique strings. The returns strings are simply integers starting from start.\n * @param start where to start the sequence\n * @return a string supplier\n */\n\n@SuppressWarnings(\"unchecked\") public static Supplier<String> createStringSupplier(int start){", "signature": "@SuppressWarnings(\"unchecked\") public static Supplier<String> createStringSupplier(int start){", "docstring": "/** \n * Create a string supplier which returns unique strings. The returns strings are simply integers starting from start.\n * @param start where to start the sequence\n * @return a string supplier\n */\n"}
|
|
{"question_id": "6367677b1a6d9265ec0182bd", "input": "/** \n * Formats a logging event to a writer.\n * @param event logging event to be formatted.\n */\n\npublic String format(final LoggingEvent event){", "signature": "public String format(final LoggingEvent event){", "docstring": "/** \n * Formats a logging event to a writer.\n * @param event logging event to be formatted.\n */\n"}
|
|
{"question_id": "636766ff1a6d9265ec017842", "input": "/** \n * <p>Converts an array of object Doubles to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Double</code> array, may be <code>null</code>\n * @return a <code>double</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n\npublic static double[] toPrimitive(final Double[] array){", "signature": "public static double[] toPrimitive(final Double[] array){", "docstring": "/** \n * <p>Converts an array of object Doubles to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Double</code> array, may be <code>null</code>\n * @return a <code>double</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n"}
|
|
{"question_id": "636766fa1a6d9265ec0177a9", "input": "/** \n * Adds an abstract type to the list of types on which a constructor is invoked in the basic block.\n * @param abstractType an abstract type on a which a constructor is invoked.\n */\n\nprivate void addInitializedType(final int abstractType){", "signature": "private void addInitializedType(final int abstractType){", "docstring": "/** \n * Adds an abstract type to the list of types on which a constructor is invoked in the basic block.\n * @param abstractType an abstract type on a which a constructor is invoked.\n */\n"}
|
|
{"question_id": "6367670a1a6d9265ec0179dc", "input": "/** \n * Puts some abstract types of {@link #currentFrame} in {@link #stackMapTableEntries} , using theJVMS verification_type_info format used in StackMapTable attributes.\n * @param start index of the first type in {@link #currentFrame} to write.\n * @param end index of last type in {@link #currentFrame} to write (exclusive).\n */\n\nprivate void putAbstractTypes(final int start,final int end){", "signature": "private void putAbstractTypes(final int start,final int end){", "docstring": "/** \n * Puts some abstract types of {@link #currentFrame} in {@link #stackMapTableEntries} , using theJVMS verification_type_info format used in StackMapTable attributes.\n * @param start index of the first type in {@link #currentFrame} to write.\n * @param end index of last type in {@link #currentFrame} to write (exclusive).\n */\n"}
|
|
{"question_id": "636766801a6d9265ec017482", "input": "/** \n * Clear and fill the buffer of this {@code ClassFileBuffer} with thesupplied byte stream. The read pointer is reset to the start of the byte array.\n */\n\npublic void readFrom(final InputStream in) throws IOException {", "signature": "public void readFrom(final InputStream in) throws IOException {", "docstring": "/** \n * Clear and fill the buffer of this {@code ClassFileBuffer} with thesupplied byte stream. The read pointer is reset to the start of the byte array.\n */\n"}
|
|
{"question_id": "6367670a1a6d9265ec0179d8", "input": "/** \n * @see OutputStream#write(byte[]) \n */\n\n@Override public void write(final byte[] b) throws IOException {", "signature": "@Override public void write(final byte[] b) throws IOException {", "docstring": "/** \n * @see OutputStream#write(byte[]) \n */\n"}
|
|
{"question_id": "636766a81a6d9265ec01757b", "input": "/** \n * Serialize to JSON {@link String}\n * @param features features to be enabled in serialization\n * @return JSON {@link String}\n */\n\n@SuppressWarnings(\"unchecked\") public String toString(JSONWriter.Feature... features){", "signature": "@SuppressWarnings(\"unchecked\") public String toString(JSONWriter.Feature... features){", "docstring": "/** \n * Serialize to JSON {@link String}\n * @param features features to be enabled in serialization\n * @return JSON {@link String}\n */\n"}
|
|
{"question_id": "636767021a6d9265ec0178bf", "input": "/** \n * <p>Convert the input object into a java.lang.Character.</p>\n * @param type Data type to which this value should be converted.\n * @param value The input value to be converted.\n * @return The converted value.\n * @throws Exception if conversion cannot be performed successfully\n * @since 1.8.0\n */\n\n@Override protected Object convertToType(final Class<?> type,final Object value) throws Exception {", "signature": "@Override protected Object convertToType(final Class<?> type,final Object value) throws Exception {", "docstring": "/** \n * <p>Convert the input object into a java.lang.Character.</p>\n * @param type Data type to which this value should be converted.\n * @param value The input value to be converted.\n * @return The converted value.\n * @throws Exception if conversion cannot be performed successfully\n * @since 1.8.0\n */\n"}
|
|
{"question_id": "6367670b1a6d9265ec017a0f", "input": "/** \n * Case in-sensitive Checks if the String contains any character in the given set of string. \n */\n\npublic static boolean containsAnyIgnoreCase(String str,List<String> searchStrArray){", "signature": "public static boolean containsAnyIgnoreCase(String str,List<String> searchStrArray){", "docstring": "/** \n * Case in-sensitive Checks if the String contains any character in the given set of string. \n */\n"}
|
|
{"question_id": "636766a81a6d9265ec01758e", "input": "/** \n * Returns a prime number which is <code>>= desiredCapacity</code> and very close to <code>desiredCapacity</code> (within 11% if <code>desiredCapacity >= 1000</code>).\n * @param desiredCapacity the capacity desired by the user.\n * @return the capacity which should be used for a hashtable.\n */\n\npublic static int nextPrime(int desiredCapacity){", "signature": "public static int nextPrime(int desiredCapacity){", "docstring": "/** \n * Returns a prime number which is <code>>= desiredCapacity</code> and very close to <code>desiredCapacity</code> (within 11% if <code>desiredCapacity >= 1000</code>).\n * @param desiredCapacity the capacity desired by the user.\n * @return the capacity which should be used for a hashtable.\n */\n"}
|
|
{"question_id": "6367670a1a6d9265ec0179cf", "input": "/** \n * <p>Converts the Character to a char handling <code>null</code>.</p> <pre> CharUtils.toChar(null, 'X') = 'X' CharUtils.toChar(' ', 'X') = ' ' CharUtils.toChar('A', 'X') = 'A' </pre>\n * @param ch the character to convert\n * @param defaultValue the value to use if the Character is null\n * @return the char value of the Character or the default if null\n */\n\npublic static char toChar(final Character ch,final char defaultValue){", "signature": "public static char toChar(final Character ch,final char defaultValue){", "docstring": "/** \n * <p>Converts the Character to a char handling <code>null</code>.</p> <pre> CharUtils.toChar(null, 'X') = 'X' CharUtils.toChar(' ', 'X') = ' ' CharUtils.toChar('A', 'X') = 'A' </pre>\n * @param ch the character to convert\n * @param defaultValue the value to use if the Character is null\n * @return the char value of the Character or the default if null\n */\n"}
|
|
{"question_id": "6367676b1a6d9265ec0181e2", "input": "/** \n * Return the first element in '<code>candidates</code>' that is contained in '<code>source</code>'. If no element in '<code>candidates</code>' is present in '<code>source</code>' returns <code>null</code>. Iteration order is {@link Collection} implementation specific.\n * @param source the source Collection\n * @param candidates the candidates to search for\n * @return the first present object, or <code>null</code> if not found\n */\n\npublic static Object findFirstMatch(Collection source,Collection candidates){", "signature": "public static Object findFirstMatch(Collection source,Collection candidates){", "docstring": "/** \n * Return the first element in '<code>candidates</code>' that is contained in '<code>source</code>'. If no element in '<code>candidates</code>' is present in '<code>source</code>' returns <code>null</code>. Iteration order is {@link Collection} implementation specific.\n * @param source the source Collection\n * @param candidates the candidates to search for\n * @return the first present object, or <code>null</code> if not found\n */\n"}
|
|
{"question_id": "6367676b1a6d9265ec0181ee", "input": "/** \n * Trim trailing whitespace from the given String.\n * @param str the String to check\n * @return the trimmed String\n * @see java.lang.Character#isWhitespace\n */\n\npublic static String trimTrailingWhitespace(String str){", "signature": "public static String trimTrailingWhitespace(String str){", "docstring": "/** \n * Trim trailing whitespace from the given String.\n * @param str the String to check\n * @return the trimmed String\n * @see java.lang.Character#isWhitespace\n */\n"}
|
|
{"question_id": "636767dc1a6d9265ec0186cb", "input": "/** \n * initialize config, such as check dist path\n */\n\npublic void init(){", "signature": "public void init(){", "docstring": "/** \n * initialize config, such as check dist path\n */\n"}
|
|
{"question_id": "636767a31a6d9265ec018552", "input": "/** \n * Read a {@code string} field value from the stream.\n */\n\n@Override public String readString() throws IOException {", "signature": "@Override public String readString() throws IOException {", "docstring": "/** \n * Read a {@code string} field value from the stream.\n */\n"}
|
|
{"question_id": "636767a61a6d9265ec0185b7", "input": "/** \n * Interpret a character as a digit (in any base up to 36) and return the numeric value. This is like {@code Character.digit()} but we don't accept non-ASCII digits.\n */\n\nprivate static int digitValue(final char c){", "signature": "private static int digitValue(final char c){", "docstring": "/** \n * Interpret a character as a digit (in any base up to 36) and return the numeric value. This is like {@code Character.digit()} but we don't accept non-ASCII digits.\n */\n"}
|
|
{"question_id": "636767e01a6d9265ec018755", "input": "/** \n * build content,if it has ats someone set the ats\n */\n\nprivate Map<String,Object> buildContent(JsonObject jsonObject){", "signature": "private Map<String,Object> buildContent(JsonObject jsonObject){", "docstring": "/** \n * build content,if it has ats someone set the ats\n */\n"}
|
|
{"question_id": "6367667f1a6d9265ec017458", "input": "/** \n * Remove an {@link AtmosphereHandler}.\n * @param mapping the mapping used when invoking {@link #addAtmosphereHandler(String,AtmosphereHandler)};\n * @return true if removed\n */\n\npublic AtmosphereFramework removeAtmosphereHandler(String mapping){", "signature": "public AtmosphereFramework removeAtmosphereHandler(String mapping){", "docstring": "/** \n * Remove an {@link AtmosphereHandler}.\n * @param mapping the mapping used when invoking {@link #addAtmosphereHandler(String,AtmosphereHandler)};\n * @return true if removed\n */\n"}
|
|
{"question_id": "636767a21a6d9265ec018517", "input": "/** \n * Returns a single byte array containg all the contents written to the buffer(s).\n */\n\npublic final byte[] toByteArray(){", "signature": "public final byte[] toByteArray(){", "docstring": "/** \n * Returns a single byte array containg all the contents written to the buffer(s).\n */\n"}
|
|
{"question_id": "6367667d1a6d9265ec017401", "input": "/** \n * <p>Unescapes any Java literals found in the <code>String</code>. For example, it will turn a sequence of <code>'\\'</code> and <code>'n'</code> into a newline character, unless the <code>'\\'</code> is preceded by another <code>'\\'</code>.</p>\n * @param str the <code>String</code> to unescape, may be null\n * @return a new unescaped <code>String</code>, <code>null</code> if null string input\n */\n\npublic static String unescapeJava(String str) throws Exception {", "signature": "public static String unescapeJava(String str) throws Exception {", "docstring": "/** \n * <p>Unescapes any Java literals found in the <code>String</code>. For example, it will turn a sequence of <code>'\\'</code> and <code>'n'</code> into a newline character, unless the <code>'\\'</code> is preceded by another <code>'\\'</code>.</p>\n * @param str the <code>String</code> to unescape, may be null\n * @return a new unescaped <code>String</code>, <code>null</code> if null string input\n */\n"}
|
|
{"question_id": "636766f01a6d9265ec01763e", "input": "/** \n * Translate a MIME standard character set name into the Java equivalent.\n * @param charset The MIME standard name.\n * @return The Java equivalent for this name.\n */\n\nprivate static String javaCharset(String charset){", "signature": "private static String javaCharset(String charset){", "docstring": "/** \n * Translate a MIME standard character set name into the Java equivalent.\n * @param charset The MIME standard name.\n * @return The Java equivalent for this name.\n */\n"}
|
|
{"question_id": "6367676a1a6d9265ec0181bf", "input": "/** \n * Turn the given Object into a String with single quotes if it is a String; keeping the Object as-is else.\n * @param obj the input Object (e.g. \"myString\")\n * @return the quoted String (e.g. \"'myString'\"),or the input object as-is if not a String\n */\n\npublic static Object quoteIfString(Object obj){", "signature": "public static Object quoteIfString(Object obj){", "docstring": "/** \n * Turn the given Object into a String with single quotes if it is a String; keeping the Object as-is else.\n * @param obj the input Object (e.g. \"myString\")\n * @return the quoted String (e.g. \"'myString'\"),or the input object as-is if not a String\n */\n"}
|
|
{"question_id": "636767501a6d9265ec017e86", "input": "/** \n * {@inheritDoc}\n */\n\n@Override public ListNode<E> previousNode(){", "signature": "@Override public ListNode<E> previousNode(){", "docstring": "/** \n * {@inheritDoc}\n */\n"}
|
|
{"question_id": "636766f21a6d9265ec017667", "input": "/** \n * Reads a signed short value in this {@link ClassReader}. <i>This method is intended for {@link Attribute} sub classes, and is normally not needed by class generators or adapters.</i>\n * @param offset the start offset of the value to be read in this {@link ClassReader}.\n * @return the read value.\n */\n\npublic short readShort(final int offset){", "signature": "public short readShort(final int offset){", "docstring": "/** \n * Reads a signed short value in this {@link ClassReader}. <i>This method is intended for {@link Attribute} sub classes, and is normally not needed by class generators or adapters.</i>\n * @param offset the start offset of the value to be read in this {@link ClassReader}.\n * @return the read value.\n */\n"}
|
|
{"question_id": "636767031a6d9265ec0178ef", "input": "/** \n * Returns a copy of the given array of size 1 greater than the argument. The last value of the array is left to the default value.\n * @param array The array to copy, must not be <code>null</code>.\n * @param newArrayComponentType If <code>array</code> is <code>null</code>, create asize 1 array of this type.\n * @return A new copy of the array of size 1 greater than the input.\n */\n\nprivate static Object copyArrayGrow1(final Object array,final Class<?> newArrayComponentType){", "signature": "private static Object copyArrayGrow1(final Object array,final Class<?> newArrayComponentType){", "docstring": "/** \n * Returns a copy of the given array of size 1 greater than the argument. The last value of the array is left to the default value.\n * @param array The array to copy, must not be <code>null</code>.\n * @param newArrayComponentType If <code>array</code> is <code>null</code>, create asize 1 array of this type.\n * @return A new copy of the array of size 1 greater than the input.\n */\n"}
|
|
{"question_id": "636767431a6d9265ec017c8d", "input": "/** \n * Computes floor($\\log_2 (n)$) $+ 1$\n */\n\nprivate int computeBinaryLog(int n){", "signature": "private int computeBinaryLog(int n){", "docstring": "/** \n * Computes floor($\\log_2 (n)$) $+ 1$\n */\n"}
|
|
{"question_id": "636767611a6d9265ec018116", "input": "/** \n * Efficient way to compute the intersection between two sets\n * @param set1 set $1$\n * @param set2 set $2$\n * @return intersection of set $1$ and $2$\n */\n\nprivate Set<V> intersection(Set<V> set1,Set<V> set2){", "signature": "private Set<V> intersection(Set<V> set1,Set<V> set2){", "docstring": "/** \n * Efficient way to compute the intersection between two sets\n * @param set1 set $1$\n * @param set2 set $2$\n * @return intersection of set $1$ and $2$\n */\n"}
|
|
{"question_id": "636766f71a6d9265ec017730", "input": "/** \n * Converts the given Collection into an array of Strings. The returned array does not contain <code>null</code> entries. Note that {@link Arrays#sort(Object[])} will throw an {@link NullPointerException} if an array element is <code>null</code>.\n * @param collection The collection to convert\n * @return A new array of Strings.\n */\n\nstatic String[] toNoNullStringArray(Collection<?> collection){", "signature": "static String[] toNoNullStringArray(Collection<?> collection){", "docstring": "/** \n * Converts the given Collection into an array of Strings. The returned array does not contain <code>null</code> entries. Note that {@link Arrays#sort(Object[])} will throw an {@link NullPointerException} if an array element is <code>null</code>.\n * @param collection The collection to convert\n * @return A new array of Strings.\n */\n"}
|
|
{"question_id": "636767081a6d9265ec0179a2", "input": "/** \n * <p>Utility method for {@link #createNumber(String)}.</p> <p>Returns <code>true</code> if s is <code>null</code>.</p>\n * @param s the String to check\n * @return if it is all zeros or <code>null</code>\n */\n\nprivate static boolean isAllZeros(String s){", "signature": "private static boolean isAllZeros(String s){", "docstring": "/** \n * <p>Utility method for {@link #createNumber(String)}.</p> <p>Returns <code>true</code> if s is <code>null</code>.</p>\n * @param s the String to check\n * @return if it is all zeros or <code>null</code>\n */\n"}
|
|
{"question_id": "636766821a6d9265ec0174b3", "input": "/** \n * Invoke the {@link BroadcastFilter}\n * @param msg\n * @return\n */\n\nprotected Object filter(Object msg){", "signature": "protected Object filter(Object msg){", "docstring": "/** \n * Invoke the {@link BroadcastFilter}\n * @param msg\n * @return\n */\n"}
|
|
{"question_id": "636767e01a6d9265ec018764", "input": "/** \n * Convert process properties to source data\n */\n\nprivate JsonObject convertProperties(List<KeyStringValuePair> properties){", "signature": "private JsonObject convertProperties(List<KeyStringValuePair> properties){", "docstring": "/** \n * Convert process properties to source data\n */\n"}
|
|
{"question_id": "6367677e1a6d9265ec018314", "input": "/** \n * Removes any inactive nodes from the Category tree.\n */\n\nprotected int removeUnusedNodes(){", "signature": "protected int removeUnusedNodes(){", "docstring": "/** \n * Removes any inactive nodes from the Category tree.\n */\n"}
|
|
{"question_id": "636766ff1a6d9265ec017853", "input": "/** \n * Returns the label corresponding to the given bytecode offset. The default implementation of this method creates a label for the given offset if it has not been already created.\n * @param bytecodeOffset a bytecode offset in a method.\n * @param labels the already created labels, indexed by their offset. If a label already existsfor bytecodeOffset this method must not create a new one. Otherwise it must store the new label in this array.\n * @return a non null Label, which must be equal to labels[bytecodeOffset].\n */\n\nprotected Label readLabel(final int bytecodeOffset,final Label[] labels){", "signature": "protected Label readLabel(final int bytecodeOffset,final Label[] labels){", "docstring": "/** \n * Returns the label corresponding to the given bytecode offset. The default implementation of this method creates a label for the given offset if it has not been already created.\n * @param bytecodeOffset a bytecode offset in a method.\n * @param labels the already created labels, indexed by their offset. If a label already existsfor bytecodeOffset this method must not create a new one. Otherwise it must store the new label in this array.\n * @return a non null Label, which must be equal to labels[bytecodeOffset].\n */\n"}
|
|
{"question_id": "6367677d1a6d9265ec0182fd", "input": "/** \n * If <code>value</code> is \"true\", then <code>true</code> is returned. If <code>value</code> is \"false\", then <code>true</code> is returned. Otherwise, <code>default</code> is returned. <p>Case of value is unimportant. \n */\n\npublic static boolean toBoolean(String value,boolean dEfault){", "signature": "public static boolean toBoolean(String value,boolean dEfault){", "docstring": "/** \n * If <code>value</code> is \"true\", then <code>true</code> is returned. If <code>value</code> is \"false\", then <code>true</code> is returned. Otherwise, <code>default</code> is returned. <p>Case of value is unimportant. \n */\n"}
|
|
{"question_id": "6367676a1a6d9265ec0181cd", "input": "/** \n * Trim leading whitespace from the given String.\n * @param str the String to check\n * @return the trimmed String\n * @see java.lang.Character#isWhitespace\n */\n\npublic static String trimLeadingWhitespace(String str){", "signature": "public static String trimLeadingWhitespace(String str){", "docstring": "/** \n * Trim leading whitespace from the given String.\n * @param str the String to check\n * @return the trimmed String\n * @see java.lang.Character#isWhitespace\n */\n"}
|
|
{"question_id": "636766fe1a6d9265ec01782a", "input": "/** \n * Reads a CONSTANT_Utf8 constant pool entry in {@link #classFileBuffer}.\n * @param constantPoolEntryIndex the index of a CONSTANT_Utf8 entry in the class's constant pooltable.\n * @param charBuffer the buffer to be used to read the string. This buffer must be sufficientlylarge. It is not automatically resized.\n * @return the String corresponding to the specified CONSTANT_Utf8 entry.\n */\n\nfinal String readUtf(final int constantPoolEntryIndex,final char[] charBuffer){", "signature": "final String readUtf(final int constantPoolEntryIndex,final char[] charBuffer){", "docstring": "/** \n * Reads a CONSTANT_Utf8 constant pool entry in {@link #classFileBuffer}.\n * @param constantPoolEntryIndex the index of a CONSTANT_Utf8 entry in the class's constant pooltable.\n * @param charBuffer the buffer to be used to read the string. This buffer must be sufficientlylarge. It is not automatically resized.\n * @return the String corresponding to the specified CONSTANT_Utf8 entry.\n */\n"}
|
|
{"question_id": "636766851a6d9265ec01751b", "input": "/** \n * Helper to decode half of a hexadecimal number from a string.\n * @param c The ASCII character of the hexadecimal number to decode.Must be in the range {@code [0-9a-fA-F]}.\n * @return The hexadecimal value represented in the ASCII charactergiven, or {@link Character#MAX_VALUE} if the character is invalid.\n */\n\nprivate static char decodeHexNibble(final char c){", "signature": "private static char decodeHexNibble(final char c){", "docstring": "/** \n * Helper to decode half of a hexadecimal number from a string.\n * @param c The ASCII character of the hexadecimal number to decode.Must be in the range {@code [0-9a-fA-F]}.\n * @return The hexadecimal value represented in the ASCII charactergiven, or {@link Character#MAX_VALUE} if the character is invalid.\n */\n"}
|
|
{"question_id": "636766f21a6d9265ec01767d", "input": "/** \n * Object to String ,when null object then null else return toString(); \n */\n\npublic static String toString(Object object){", "signature": "public static String toString(Object object){", "docstring": "/** \n * Object to String ,when null object then null else return toString(); \n */\n"}
|
|
{"question_id": "636767581a6d9265ec017fc4", "input": "/** \n * Calculate the factorial of $n$.\n * @param n the input number\n * @return the factorial\n */\n\npublic static long factorial(int n){", "signature": "public static long factorial(int n){", "docstring": "/** \n * Calculate the factorial of $n$.\n * @param n the input number\n * @return the factorial\n */\n"}
|
|
{"question_id": "636767511a6d9265ec017eb6", "input": "/** \n * Either finds and returns a circulator to the node on the boundary of the component, which satisfies the {@code predicate} or returns a circulator to the {@code stop} node.\n * @param predicate the condition the desired node should satisfy\n * @param start the node to start the search from\n * @param stop the node to end the search with\n * @param dir the direction to start the traversal in\n * @return a circulator to the node satisfying the {@code predicate} or to the {@code stop} node\n */\n\nprivate OuterFaceCirculator selectOnOuterFace(Predicate<Node> predicate,Node start,Node stop,int dir){", "signature": "private OuterFaceCirculator selectOnOuterFace(Predicate<Node> predicate,Node start,Node stop,int dir){", "docstring": "/** \n * Either finds and returns a circulator to the node on the boundary of the component, which satisfies the {@code predicate} or returns a circulator to the {@code stop} node.\n * @param predicate the condition the desired node should satisfy\n * @param start the node to start the search from\n * @param stop the node to end the search with\n * @param dir the direction to start the traversal in\n * @return a circulator to the node satisfying the {@code predicate} or to the {@code stop} node\n */\n"}
|
|
{"question_id": "636767841a6d9265ec0183e8", "input": "/** \n * Add an <code>event</code> as the last event in the buffer.\n */\n\npublic void add(LoggingEvent event){", "signature": "public void add(LoggingEvent event){", "docstring": "/** \n * Add an <code>event</code> as the last event in the buffer.\n */\n"}
|
|
{"question_id": "636767a41a6d9265ec01857e", "input": "/** \n * Compares the two specified {@code long} values. The sign of the value returned is the same as that of{@code ((Long) a).compareTo(b)}. <p> <b>Note for Java 7 and later:</b> this method should be treated as deprecated; use the equivalent {@link Long#compare} method instead.\n * @param a the first {@code long} to compare\n * @param b the second {@code long} to compare\n * @return a negative value if {@code a} is less than {@code b}; a positive value if {@code a} is greater than{@code b}; or zero if they are equal\n */\n\nprivate static int compareSigned(long a,long b){", "signature": "private static int compareSigned(long a,long b){", "docstring": "/** \n * Compares the two specified {@code long} values. The sign of the value returned is the same as that of{@code ((Long) a).compareTo(b)}. <p> <b>Note for Java 7 and later:</b> this method should be treated as deprecated; use the equivalent {@link Long#compare} method instead.\n * @param a the first {@code long} to compare\n * @param b the second {@code long} to compare\n * @return a negative value if {@code a} is less than {@code b}; a positive value if {@code a} is greater than{@code b}; or zero if they are equal\n */\n"}
|
|
{"question_id": "636767691a6d9265ec0181ae", "input": "/** \n * Copy the given Enumeration into a String array. The Enumeration must contain String elements only.\n * @param enumeration the Enumeration to copy\n * @return the String array (<code>null</code> if the passed-inEnumeration was <code>null</code>)\n */\n\npublic static String[] toStringArray(Enumeration<String> enumeration){", "signature": "public static String[] toStringArray(Enumeration<String> enumeration){", "docstring": "/** \n * Copy the given Enumeration into a String array. The Enumeration must contain String elements only.\n * @param enumeration the Enumeration to copy\n * @return the String array (<code>null</code> if the passed-inEnumeration was <code>null</code>)\n */\n"}
|
|
{"question_id": "636766a91a6d9265ec0175ae", "input": "/** \n * Puts an array of bytes into this byte vector. The byte vector is automatically enlarged if necessary.\n * @param byteArrayValue an array of bytes. May be {@literal null} to put {@code byteLength} nullbytes into this byte vector.\n * @param byteOffset index of the first byte of byteArrayValue that must be copied.\n * @param byteLength number of bytes of byteArrayValue that must be copied.\n * @return this byte vector.\n */\n\npublic ByteVector putByteArray(final byte[] byteArrayValue,final int byteOffset,final int byteLength){", "signature": "public ByteVector putByteArray(final byte[] byteArrayValue,final int byteOffset,final int byteLength){", "docstring": "/** \n * Puts an array of bytes into this byte vector. The byte vector is automatically enlarged if necessary.\n * @param byteArrayValue an array of bytes. May be {@literal null} to put {@code byteLength} nullbytes into this byte vector.\n * @param byteOffset index of the first byte of byteArrayValue that must be copied.\n * @param byteLength number of bytes of byteArrayValue that must be copied.\n * @return this byte vector.\n */\n"}
|
|
{"question_id": "636766f11a6d9265ec01764f", "input": "/** \n * Returns the values for the BeanMap.\n * @return values for the BeanMap. The returned collection is not modifiable.\n */\n\npublic Collection<Object> values(){", "signature": "public Collection<Object> values(){", "docstring": "/** \n * Returns the values for the BeanMap.\n * @return values for the BeanMap. The returned collection is not modifiable.\n */\n"}
|
|
{"question_id": "636766f81a6d9265ec017758", "input": "/** \n * Returns a hash code value for this type.\n * @return a hash code value for this type.\n */\n\n@Override public int hashCode(){", "signature": "@Override public int hashCode(){", "docstring": "/** \n * Returns a hash code value for this type.\n * @return a hash code value for this type.\n */\n"}
|
|
{"question_id": "6367676c1a6d9265ec01820b", "input": "/** \n * Delete any character in a given String.\n * @param inString the original String\n * @param charsToDelete a set of characters to delete.E.g. \"az\\n\" will delete 'a's, 'z's and new lines.\n * @return the resulting String\n */\n\npublic static String deleteAny(String inString,String charsToDelete){", "signature": "public static String deleteAny(String inString,String charsToDelete){", "docstring": "/** \n * Delete any character in a given String.\n * @param inString the original String\n * @param charsToDelete a set of characters to delete.E.g. \"az\\n\" will delete 'a's, 'z's and new lines.\n * @return the resulting String\n */\n"}
|
|
{"question_id": "636766861a6d9265ec01755a", "input": "/** \n * Match a URI against the pattern.\n * @param uri the uri to match against the template.\n * @return the match result, otherwise null if no match occurs.\n */\n\npublic final MatchResult match(CharSequence uri){", "signature": "public final MatchResult match(CharSequence uri){", "docstring": "/** \n * Match a URI against the pattern.\n * @param uri the uri to match against the template.\n * @return the match result, otherwise null if no match occurs.\n */\n"}
|
|
{"question_id": "636766f91a6d9265ec01777d", "input": "/** \n * @param b An ASCII encoded character 0-9 a-f A-F\n * @return The byte value of the character 0-16.\n */\n\npublic static byte convertHexDigit(byte b){", "signature": "public static byte convertHexDigit(byte b){", "docstring": "/** \n * @param b An ASCII encoded character 0-9 a-f A-F\n * @return The byte value of the character 0-16.\n */\n"}
|
|
{"question_id": "636766801a6d9265ec017477", "input": "/** \n * Add the specified files in reverse order.\n */\n\nprivate void addReverse(final InputStream[] files){", "signature": "private void addReverse(final InputStream[] files){", "docstring": "/** \n * Add the specified files in reverse order.\n */\n"}
|
|
{"question_id": "636767de1a6d9265ec01871e", "input": "/** \n * @param modelName model name of the entity\n * @throws IllegalStateException if sharding key indices are not continuous\n */\n\nprivate void check(String modelName) throws IllegalStateException {", "signature": "private void check(String modelName) throws IllegalStateException {", "docstring": "/** \n * @param modelName model name of the entity\n * @throws IllegalStateException if sharding key indices are not continuous\n */\n"}
|
|
{"question_id": "636766f81a6d9265ec01774b", "input": "/** \n * Reads a byte from the <code>buffer</code>, and refills it as necessary.\n * @return The next byte from the input stream.\n * @throws IOException if there is no more data available.\n */\n\npublic byte readByte() throws IOException {", "signature": "public byte readByte() throws IOException {", "docstring": "/** \n * Reads a byte from the <code>buffer</code>, and refills it as necessary.\n * @return The next byte from the input stream.\n * @throws IOException if there is no more data available.\n */\n"}
|
|
{"question_id": "636766851a6d9265ec017515", "input": "/** \n * Automatically suspend the {@link AtmosphereResource} based on {@link AtmosphereResource.TRANSPORT} value.\n * @param r a {@link AtmosphereResource}\n * @return {@link Action#CONTINUE}\n */\n\n@Override public Action inspect(AtmosphereResource r){", "signature": "@Override public Action inspect(AtmosphereResource r){", "docstring": "/** \n * Automatically suspend the {@link AtmosphereResource} based on {@link AtmosphereResource.TRANSPORT} value.\n * @param r a {@link AtmosphereResource}\n * @return {@link Action#CONTINUE}\n */\n"}
|
|
{"question_id": "636767611a6d9265ec018106", "input": "/** \n * Compute the sum of the weights entering a vertex\n * @param v the vertex\n * @return the sum of the weights entering a vertex\n */\n\npublic double vertexWeight(Set<V> v){", "signature": "public double vertexWeight(Set<V> v){", "docstring": "/** \n * Compute the sum of the weights entering a vertex\n * @param v the vertex\n * @return the sum of the weights entering a vertex\n */\n"}
|
|
{"question_id": "636767841a6d9265ec0183f2", "input": "/** \n * @see Comparator \n */\n\npublic int compare(Object aObj1,Object aObj2){", "signature": "public int compare(Object aObj1,Object aObj2){", "docstring": "/** \n * @see Comparator \n */\n"}
|
|
{"question_id": "636767861a6d9265ec01844c", "input": "/** \n * Remove the appender with the name passed as parameter form the list of appenders. \n */\n\npublic void removeAppender(String name){", "signature": "public void removeAppender(String name){", "docstring": "/** \n * Remove the appender with the name passed as parameter form the list of appenders. \n */\n"}
|
|
{"question_id": "636767781a6d9265ec018242", "input": "/** \n * Call the <code>doAppend</code> method on all attached appenders. \n */\n\npublic int appendLoopOnAppenders(LoggingEvent event){", "signature": "public int appendLoopOnAppenders(LoggingEvent event){", "docstring": "/** \n * Call the <code>doAppend</code> method on all attached appenders. \n */\n"}
|
|
{"question_id": "6367670c1a6d9265ec017a2a", "input": "/** \n * <p>Converts an array of object Integers to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Integer</code> array, may be <code>null</code>\n * @return an <code>int</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n\npublic static int[] toPrimitive(final Integer[] array){", "signature": "public static int[] toPrimitive(final Integer[] array){", "docstring": "/** \n * <p>Converts an array of object Integers to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Integer</code> array, may be <code>null</code>\n * @return an <code>int</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n"}
|
|
{"question_id": "636767041a6d9265ec017911", "input": "/** \n * <p> Registers the given object. Used by the reflection methods to avoid infinite loops. </p>\n * @param value The object to register.\n */\n\nstatic void register(Object value){", "signature": "static void register(Object value){", "docstring": "/** \n * <p> Registers the given object. Used by the reflection methods to avoid infinite loops. </p>\n * @param value The object to register.\n */\n"}
|
|
{"question_id": "636767511a6d9265ec017eb0", "input": "/** \n * Get the number of non-zero entries of a row.\n * @param row the row\n * @return the number of non-zero entries of a row\n */\n\npublic int nonZeros(int row){", "signature": "public int nonZeros(int row){", "docstring": "/** \n * Get the number of non-zero entries of a row.\n * @param row the row\n * @return the number of non-zero entries of a row\n */\n"}
|
|
{"question_id": "6367676c1a6d9265ec018223", "input": "/** \n * Check whether the given Collection contains the given element instance. <p>Enforces the given instance to be present, rather than returning <code>true</code> for an equal element as well.\n * @param collection the Collection to check\n * @param element the element to look for\n * @return <code>true</code> if found, <code>false</code> else\n */\n\npublic static boolean containsInstance(Collection collection,Object element){", "signature": "public static boolean containsInstance(Collection collection,Object element){", "docstring": "/** \n * Check whether the given Collection contains the given element instance. <p>Enforces the given instance to be present, rather than returning <code>true</code> for an equal element as well.\n * @param collection the Collection to check\n * @param element the element to look for\n * @return <code>true</code> if found, <code>false</code> else\n */\n"}
|
|
{"question_id": "636766fa1a6d9265ec01779d", "input": "/** \n * <p>Checks whether the character is ASCII 7 bit control.</p> <pre> CharUtils.isAsciiControl('a') = false CharUtils.isAsciiControl('A') = false CharUtils.isAsciiControl('3') = false CharUtils.isAsciiControl('-') = false CharUtils.isAsciiControl('\\n') = true CharUtils.isAsciiControl('©') = false </pre>\n * @param ch the character to check\n * @return true if less than 32 or equals 127\n */\n\npublic static boolean isAsciiControl(final char ch){", "signature": "public static boolean isAsciiControl(final char ch){", "docstring": "/** \n * <p>Checks whether the character is ASCII 7 bit control.</p> <pre> CharUtils.isAsciiControl('a') = false CharUtils.isAsciiControl('A') = false CharUtils.isAsciiControl('3') = false CharUtils.isAsciiControl('-') = false CharUtils.isAsciiControl('\\n') = true CharUtils.isAsciiControl('©') = false </pre>\n * @param ch the character to check\n * @return true if less than 32 or equals 127\n */\n"}
|
|
{"question_id": "6367670b1a6d9265ec0179f2", "input": "/** \n * Return <code>true</code> if this map contains a mapping for the specified key.\n * @param key the key to be searched for\n * @return true if the map contains the key\n */\n\n@Override public boolean containsKey(final Object key){", "signature": "@Override public boolean containsKey(final Object key){", "docstring": "/** \n * Return <code>true</code> if this map contains a mapping for the specified key.\n * @param key the key to be searched for\n * @return true if the map contains the key\n */\n"}
|
|
{"question_id": "636766fa1a6d9265ec017796", "input": "/** \n * <p>Converts an array of primitive booleans to objects.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>boolean</code> array\n * @return a <code>Boolean</code> array, <code>null</code> if null array input\n */\n\npublic static Boolean[] toObject(final boolean[] array){", "signature": "public static Boolean[] toObject(final boolean[] array){", "docstring": "/** \n * <p>Converts an array of primitive booleans to objects.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>boolean</code> array\n * @return a <code>Boolean</code> array, <code>null</code> if null array input\n */\n"}
|
|
{"question_id": "636767aa1a6d9265ec01864a", "input": "/** \n * Copies bytes to a {@code byte[]}.\n */\n\npublic byte[] toByteArray(){", "signature": "public byte[] toByteArray(){", "docstring": "/** \n * Copies bytes to a {@code byte[]}.\n */\n"}
|
|
{"question_id": "636767561a6d9265ec017f7c", "input": "/** \n * Transform from a Set representation to a graph path.\n * @param tour a set containing the edges of the tour\n * @param graph the graph\n * @return a graph path\n */\n\nprotected GraphPath<V,E> edgeSetToTour(Set<E> tour,Graph<V,E> graph){", "signature": "protected GraphPath<V,E> edgeSetToTour(Set<E> tour,Graph<V,E> graph){", "docstring": "/** \n * Transform from a Set representation to a graph path.\n * @param tour a set containing the edges of the tour\n * @param graph the graph\n * @return a graph path\n */\n"}
|
|
{"question_id": "6367670a1a6d9265ec0179f1", "input": "/** \n * <p>Converts an array of primitive shorts to objects.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>short</code> array\n * @return a <code>Short</code> array, <code>null</code> if null array input\n */\n\npublic static Short[] toObject(final short[] array){", "signature": "public static Short[] toObject(final short[] array){", "docstring": "/** \n * <p>Converts an array of primitive shorts to objects.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>short</code> array\n * @return a <code>Short</code> array, <code>null</code> if null array input\n */\n"}
|
|
{"question_id": "636766fe1a6d9265ec017823", "input": "/** \n * Adds a CONSTANT_NameAndType_info to the constant pool of this symbol table. Does nothing if the constant pool already contains a similar item.\n * @param name a field or method name.\n * @param descriptor a field or method descriptor.\n * @return a new or already existing Symbol with the given value.\n */\n\nint addConstantNameAndType(final String name,final String descriptor){", "signature": "int addConstantNameAndType(final String name,final String descriptor){", "docstring": "/** \n * Adds a CONSTANT_NameAndType_info to the constant pool of this symbol table. Does nothing if the constant pool already contains a similar item.\n * @param name a field or method name.\n * @param descriptor a field or method descriptor.\n * @return a new or already existing Symbol with the given value.\n */\n"}
|
|
{"question_id": "636767461a6d9265ec017d17", "input": "/** \n * Unescape a string DOT identifier.\n * @param input the input\n * @return the unescaped output\n */\n\nprivate String unescapeId(String input){", "signature": "private String unescapeId(String input){", "docstring": "/** \n * Unescape a string DOT identifier.\n * @param input the input\n * @return the unescaped output\n */\n"}
|
|
{"question_id": "6367676c1a6d9265ec018204", "input": "/** \n * Concatenate the given String arrays into one, with overlapping array elements included twice. <p>The order of elements in the original arrays is preserved.\n * @param array1 the first array (can be <code>null</code>)\n * @param array2 the second array (can be <code>null</code>)\n * @return the new array (<code>null</code> if both given arrays were <code>null</code>)\n */\n\npublic static String[] concatenateStringArrays(String[] array1,String[] array2){", "signature": "public static String[] concatenateStringArrays(String[] array1,String[] array2){", "docstring": "/** \n * Concatenate the given String arrays into one, with overlapping array elements included twice. <p>The order of elements in the original arrays is preserved.\n * @param array1 the first array (can be <code>null</code>)\n * @param array2 the second array (can be <code>null</code>)\n * @return the new array (<code>null</code> if both given arrays were <code>null</code>)\n */\n"}
|
|
{"question_id": "636767641a6d9265ec018190", "input": "/** \n * Moves all vertices from the bucket with label {@code minLabel} to the bucket with label 0.Clears the bucket with label {@code minLabel}. Updates the labeling accordingly.\n * @param bucketsByLabel the buckets vertices are stored in\n * @param labels the labels of the vertices\n * @param minLabel the minimum value of the non-empty bucket\n */\n\nprivate void reload(List<Set<Integer>> bucketsByLabel,List<Integer> labels,int minLabel){", "signature": "private void reload(List<Set<Integer>> bucketsByLabel,List<Integer> labels,int minLabel){", "docstring": "/** \n * Moves all vertices from the bucket with label {@code minLabel} to the bucket with label 0.Clears the bucket with label {@code minLabel}. Updates the labeling accordingly.\n * @param bucketsByLabel the buckets vertices are stored in\n * @param labels the labels of the vertices\n * @param minLabel the minimum value of the non-empty bucket\n */\n"}
|
|
{"question_id": "6367676a1a6d9265ec0181d4", "input": "/** \n * Append the given String to the given String array, returning a new array consisting of the input array contents plus the given String.\n * @param array the array to append to (can be <code>null</code>)\n * @param str the String to append\n * @return the new array (never <code>null</code>)\n */\n\npublic static String[] addStringToArray(String[] array,String str){", "signature": "public static String[] addStringToArray(String[] array,String str){", "docstring": "/** \n * Append the given String to the given String array, returning a new array consisting of the input array contents plus the given String.\n * @param array the array to append to (can be <code>null</code>)\n * @param str the String to append\n * @return the new array (never <code>null</code>)\n */\n"}
|
|
{"question_id": "6367676b1a6d9265ec0181dd", "input": "/** \n * Returns the number of occurrences the substring {@code sub} appears in string {@code str}.\n * @param str string to search in. Return 0 if this is null.\n * @param sub string to search for. Return 0 if this is null.\n * @return the number of occurrences the substring {@code sub} appears in string {@code str}.\n */\n\npublic static int countOccurrencesOf(String str,String sub){", "signature": "public static int countOccurrencesOf(String str,String sub){", "docstring": "/** \n * Returns the number of occurrences the substring {@code sub} appears in string {@code str}.\n * @param str string to search in. Return 0 if this is null.\n * @param sub string to search for. Return 0 if this is null.\n * @return the number of occurrences the substring {@code sub} appears in string {@code str}.\n */\n"}
|
|
{"question_id": "636766811a6d9265ec017499", "input": "/** \n * <p> Checks in the specified list if there is at least one instance of the given {@link AtmosphereInterceptor interceptor} implementation class.</p>\n * @param interceptorList the interceptors\n * @param c the interceptor class\n * @return {@code false} if an instance of the class already exists in the list, {@code true} otherwise\n */\n\nprivate boolean checkDuplicate(final List<AtmosphereInterceptor> interceptorList,Class<? extends AtmosphereInterceptor> c){", "signature": "private boolean checkDuplicate(final List<AtmosphereInterceptor> interceptorList,Class<? extends AtmosphereInterceptor> c){", "docstring": "/** \n * <p> Checks in the specified list if there is at least one instance of the given {@link AtmosphereInterceptor interceptor} implementation class.</p>\n * @param interceptorList the interceptors\n * @param c the interceptor class\n * @return {@code false} if an instance of the class already exists in the list, {@code true} otherwise\n */\n"}
|
|
{"question_id": "636766fe1a6d9265ec017821", "input": "/** \n * <p>Append to the <code>toString</code> the detail of a <code>byte</code> array.</p>\n * @param buffer the <code>StringBuffer</code> to populate\n * @param fieldName the field name, typically not used as already appended\n * @param array the array to add to the <code>toString</code>,not <code>null</code>\n */\n\nprotected void appendDetail(StringBuffer buffer,String fieldName,byte[] array){", "signature": "protected void appendDetail(StringBuffer buffer,String fieldName,byte[] array){", "docstring": "/** \n * <p>Append to the <code>toString</code> the detail of a <code>byte</code> array.</p>\n * @param buffer the <code>StringBuffer</code> to populate\n * @param fieldName the field name, typically not used as already appended\n * @param array the array to add to the <code>toString</code>,not <code>null</code>\n */\n"}
|
|
{"question_id": "636767561a6d9265ec017f63", "input": "/** \n * Checks whether there exist unvisited vertices.\n * @return true if there exist unvisited vertices.\n */\n\n@Override public boolean hasNext(){", "signature": "@Override public boolean hasNext(){", "docstring": "/** \n * Checks whether there exist unvisited vertices.\n * @return true if there exist unvisited vertices.\n */\n"}
|
|
{"question_id": "636766a81a6d9265ec017586", "input": "/** \n * Pops the given number of abstract types from the output frame stack.\n * @param elements the number of abstract types that must be popped.\n */\n\nprivate void pop(final int elements){", "signature": "private void pop(final int elements){", "docstring": "/** \n * Pops the given number of abstract types from the output frame stack.\n * @param elements the number of abstract types that must be popped.\n */\n"}
|
|
{"question_id": "636767e11a6d9265ec018795", "input": "/** \n * @return true if the bucket is same.\n */\n\npublic boolean isCompatible(DataTable dataset){", "signature": "public boolean isCompatible(DataTable dataset){", "docstring": "/** \n * @return true if the bucket is same.\n */\n"}
|
|
{"question_id": "636767791a6d9265ec018263", "input": "/** \n * Find class given class name.\n * @param className class name, may not be null.\n * @return class, will not be null.\n * @throws ClassNotFoundException thrown if class can not be found.\n */\n\nprivate Class findClass(final String className) throws ClassNotFoundException {", "signature": "private Class findClass(final String className) throws ClassNotFoundException {", "docstring": "/** \n * Find class given class name.\n * @param className class name, may not be null.\n * @return class, will not be null.\n * @throws ClassNotFoundException thrown if class can not be found.\n */\n"}
|
|
{"question_id": "636767611a6d9265ec018112", "input": "/** \n * {@inheritDoc}\n */\n\n@Override protected V provideNextVertex(){", "signature": "@Override protected V provideNextVertex(){", "docstring": "/** \n * {@inheritDoc}\n */\n"}
|
|
{"question_id": "636767131a6d9265ec017b23", "input": "/** \n * Adds a source line number corresponding to this label.\n * @param lineNumber a source line number (which should be strictly positive).\n */\n\nfinal void addLineNumber(final int lineNumber){", "signature": "final void addLineNumber(final int lineNumber){", "docstring": "/** \n * Adds a source line number corresponding to this label.\n * @param lineNumber a source line number (which should be strictly positive).\n */\n"}
|
|
{"question_id": "6367675a1a6d9265ec018010", "input": "/** \n * Removes this bucket from the data structure.\n */\n\nvoid removeSelf(){", "signature": "void removeSelf(){", "docstring": "/** \n * Removes this bucket from the data structure.\n */\n"}
|
|
{"question_id": "636767dd1a6d9265ec0186f3", "input": "/** \n * Keep the same name replacement as {@link ColumnName#overrideName(String,String)}\n * @param oldName to be replaced.\n * @param newName to use in the storage level.\n */\n\npublic void overrideName(String oldName,String newName){", "signature": "public void overrideName(String oldName,String newName){", "docstring": "/** \n * Keep the same name replacement as {@link ColumnName#overrideName(String,String)}\n * @param oldName to be replaced.\n * @param newName to use in the storage level.\n */\n"}
|
|
{"question_id": "636767631a6d9265ec018171", "input": "/** \n * Remove the non null {@code node} from the list. \n */\n\nprivate boolean unlink(ListNodeImpl<E> node){", "signature": "private boolean unlink(ListNodeImpl<E> node){", "docstring": "/** \n * Remove the non null {@code node} from the list. \n */\n"}
|
|
{"question_id": "636767de1a6d9265ec018726", "input": "/** \n * build current profiles segment snapshot search sequence ranges\n */\n\npublic List<SequenceRange> buildSequenceRanges(){", "signature": "public List<SequenceRange> buildSequenceRanges(){", "docstring": "/** \n * build current profiles segment snapshot search sequence ranges\n */\n"}
|
|
{"question_id": "6367667c1a6d9265ec0173f7", "input": "/** \n * True is the body is a byte array\n * @return True is the body is a byte array\n */\n\npublic boolean hasBytes(){", "signature": "public boolean hasBytes(){", "docstring": "/** \n * True is the body is a byte array\n * @return True is the body is a byte array\n */\n"}
|
|
{"question_id": "6367676c1a6d9265ec018220", "input": "/** \n * Strip the filename extension from the given path, e.g. \"mypath/myfile.txt\" -> \"mypath/myfile\".\n * @param path the file path (may be <code>null</code>)\n * @return the path with stripped filename extension,or <code>null</code> if none\n */\n\npublic static String stripFilenameExtension(String path){", "signature": "public static String stripFilenameExtension(String path){", "docstring": "/** \n * Strip the filename extension from the given path, e.g. \"mypath/myfile.txt\" -> \"mypath/myfile\".\n * @param path the file path (may be <code>null</code>)\n * @return the path with stripped filename extension,or <code>null</code> if none\n */\n"}
|
|
{"question_id": "636766fe1a6d9265ec017838", "input": "/** \n * <p>Converts an array of object Characters to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Character</code> array, may be <code>null</code>\n * @return a <code>char</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n\npublic static char[] toPrimitive(final Character[] array){", "signature": "public static char[] toPrimitive(final Character[] array){", "docstring": "/** \n * <p>Converts an array of object Characters to primitives.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>Character</code> array, may be <code>null</code>\n * @return a <code>char</code> array, <code>null</code> if null array input\n * @throws NullPointerException if array content is <code>null</code>\n */\n"}
|
|
{"question_id": "636766fa1a6d9265ec01779c", "input": "/** \n * Parses out a token until any of the given terminators is encountered.\n * @param terminators the array of terminating characters. Any of these characters when encountered signify the end of the token\n * @return the token\n */\n\nprivate String parseToken(final char[] terminators){", "signature": "private String parseToken(final char[] terminators){", "docstring": "/** \n * Parses out a token until any of the given terminators is encountered.\n * @param terminators the array of terminating characters. Any of these characters when encountered signify the end of the token\n * @return the token\n */\n"}
|
|
{"question_id": "636767691a6d9265ec0181a7", "input": "/** \n * Trim all occurrences of the supplied leading character from the given String.\n * @param str the String to check\n * @param leadingCharacter the leading character to be trimmed\n * @return the trimmed String\n */\n\npublic static String trimLeadingCharacter(String str,char leadingCharacter){", "signature": "public static String trimLeadingCharacter(String str,char leadingCharacter){", "docstring": "/** \n * Trim all occurrences of the supplied leading character from the given String.\n * @param str the String to check\n * @param leadingCharacter the leading character to be trimmed\n * @return the trimmed String\n */\n"}
|
|
{"question_id": "636767041a6d9265ec01790f", "input": "/** \n * <p>Converts an array of primitive ints to objects.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array an <code>int</code> array\n * @return an <code>Integer</code> array, <code>null</code> if null array input\n */\n\npublic static Integer[] toObject(final int[] array){", "signature": "public static Integer[] toObject(final int[] array){", "docstring": "/** \n * <p>Converts an array of primitive ints to objects.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array an <code>int</code> array\n * @return an <code>Integer</code> array, <code>null</code> if null array input\n */\n"}
|
|
{"question_id": "636766fa1a6d9265ec0177a4", "input": "/** \n * <p>Converts an array of primitive doubles to objects.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>double</code> array\n * @return a <code>Double</code> array, <code>null</code> if null array input\n */\n\npublic static Double[] toObject(final double[] array){", "signature": "public static Double[] toObject(final double[] array){", "docstring": "/** \n * <p>Converts an array of primitive doubles to objects.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array a <code>double</code> array\n * @return a <code>Double</code> array, <code>null</code> if null array input\n */\n"}
|
|
{"question_id": "636767461a6d9265ec017d0e", "input": "/** \n * Computes a suffix sum of the {@code bounds}. Returns computed suffix sum and the sum of all elements in the {@code bounds list}.\n * @param bounds list of integers.\n * @return computed pair of suffix sum list and a sum of all elements.\n */\n\nprivate Pair<List<Integer>,Long> computeSuffixSum(List<Integer> bounds){", "signature": "private Pair<List<Integer>,Long> computeSuffixSum(List<Integer> bounds){", "docstring": "/** \n * Computes a suffix sum of the {@code bounds}. Returns computed suffix sum and the sum of all elements in the {@code bounds list}.\n * @param bounds list of integers.\n * @return computed pair of suffix sum list and a sum of all elements.\n */\n"}
|
|
{"question_id": "636767491a6d9265ec017d90", "input": "/** \n * Reverses the order of the elements in the specified range within the given array.\n * @param < V > the type of elements in the array\n * @param arr the array\n * @param from the index of the first element (inclusive) inside the range to reverse\n * @param to the index of the last element (inclusive) inside the range to reverse\n */\n\npublic static final <V>void reverse(V[] arr,int from,int to){", "signature": "public static final <V>void reverse(V[] arr,int from,int to){", "docstring": "/** \n * Reverses the order of the elements in the specified range within the given array.\n * @param < V > the type of elements in the array\n * @param arr the array\n * @param from the index of the first element (inclusive) inside the range to reverse\n * @param to the index of the last element (inclusive) inside the range to reverse\n */\n"}
|
|
{"question_id": "6367674a1a6d9265ec017da9", "input": "/** \n * Atomically moves all {@link ListNode ListNodes} from {@code list} to this list as if eachnode was removed with {@link #removeListNode(ListNodeImpl)} from {@code list} andsubsequently added to this list by {@link #addListNode(ListNodeImpl)}.\n */\n\nprivate void moveAllListNodes(DoublyLinkedList<E> list){", "signature": "private void moveAllListNodes(DoublyLinkedList<E> list){", "docstring": "/** \n * Atomically moves all {@link ListNode ListNodes} from {@code list} to this list as if eachnode was removed with {@link #removeListNode(ListNodeImpl)} from {@code list} andsubsequently added to this list by {@link #addListNode(ListNodeImpl)}.\n */\n"}
|
|
{"question_id": "636767151a6d9265ec017b6b", "input": "/** \n * <p>Check if a String starts with a specified prefix (optionally case insensitive).</p>\n * @see String#startsWith(String)\n * @param str the String to check, may be null\n * @param prefix the prefix to find, may be null\n * @param ignoreCase inidicates whether the compare should ignore case(case insensitive) or not.\n * @return <code>true</code> if the String starts with the prefix orboth <code>null</code>\n */\n\nprivate static boolean startsWith(final String str,final String prefix,final boolean ignoreCase){", "signature": "private static boolean startsWith(final String str,final String prefix,final boolean ignoreCase){", "docstring": "/** \n * <p>Check if a String starts with a specified prefix (optionally case insensitive).</p>\n * @see String#startsWith(String)\n * @param str the String to check, may be null\n * @param prefix the prefix to find, may be null\n * @param ignoreCase inidicates whether the compare should ignore case(case insensitive) or not.\n * @return <code>true</code> if the String starts with the prefix orboth <code>null</code>\n */\n"}
|
|
{"question_id": "636766fe1a6d9265ec01781c", "input": "/** \n * <p>Converts the character to a Character.</p> <p>For ASCII 7 bit characters, this uses a cache that will return the same Character object each time.</p> <pre> CharUtils.toCharacterObject(' ') = ' ' CharUtils.toCharacterObject('A') = 'A' </pre>\n * @param ch the character to convert\n * @return a Character of the specified character\n */\n\npublic static Character toCharacterObject(final char ch){", "signature": "public static Character toCharacterObject(final char ch){", "docstring": "/** \n * <p>Converts the character to a Character.</p> <p>For ASCII 7 bit characters, this uses a cache that will return the same Character object each time.</p> <pre> CharUtils.toCharacterObject(' ') = ' ' CharUtils.toCharacterObject('A') = 'A' </pre>\n * @param ch the character to convert\n * @return a Character of the specified character\n */\n"}
|
|
{"question_id": "636766fb1a6d9265ec0177c1", "input": "/** \n * <p>Checks whether the character is ASCII 7 bit alphabetic upper case.</p> <pre> CharUtils.isAsciiAlphaUpper('a') = false CharUtils.isAsciiAlphaUpper('A') = true CharUtils.isAsciiAlphaUpper('3') = false CharUtils.isAsciiAlphaUpper('-') = false CharUtils.isAsciiAlphaUpper('\\n') = false CharUtils.isAsciiAlphaUpper('©') = false </pre>\n * @param ch the character to check\n * @return true if between 65 and 90 inclusive\n */\n\npublic static boolean isAsciiAlphaUpper(final char ch){", "signature": "public static boolean isAsciiAlphaUpper(final char ch){", "docstring": "/** \n * <p>Checks whether the character is ASCII 7 bit alphabetic upper case.</p> <pre> CharUtils.isAsciiAlphaUpper('a') = false CharUtils.isAsciiAlphaUpper('A') = true CharUtils.isAsciiAlphaUpper('3') = false CharUtils.isAsciiAlphaUpper('-') = false CharUtils.isAsciiAlphaUpper('\\n') = false CharUtils.isAsciiAlphaUpper('©') = false </pre>\n * @param ch the character to check\n * @return true if between 65 and 90 inclusive\n */\n"}
|
|
{"question_id": "636767781a6d9265ec018250", "input": "/** \n * Returns {@link Filter#NEUTRAL} is there is no string match.\n */\n\npublic int decide(LoggingEvent event){", "signature": "public int decide(LoggingEvent event){", "docstring": "/** \n * Returns {@link Filter#NEUTRAL} is there is no string match.\n */\n"}
|
|
{"question_id": "636766861a6d9265ec017553", "input": "/** \n * Ascertain if a template variable is a member of this template.\n * @param name name The template variable.\n * @return true if the template variable is a member of the template, otherwisefalse.\n */\n\npublic final boolean isTemplateVariablePresent(String name){", "signature": "public final boolean isTemplateVariablePresent(String name){", "docstring": "/** \n * Ascertain if a template variable is a member of this template.\n * @param name name The template variable.\n * @return true if the template variable is a member of the template, otherwisefalse.\n */\n"}
|
|
{"question_id": "636767071a6d9265ec017962", "input": "/** \n * Puts all of the writable properties from the given BeanMap into this BeanMap. Read-only and Write-only properties will be ignored.\n * @param map the BeanMap whose properties to put\n */\n\npublic void putAllWriteable(BeanMap map){", "signature": "public void putAllWriteable(BeanMap map){", "docstring": "/** \n * Puts all of the writable properties from the given BeanMap into this BeanMap. Read-only and Write-only properties will be ignored.\n * @param map the BeanMap whose properties to put\n */\n"}
|
|
{"question_id": "6367670a1a6d9265ec0179d9", "input": "/** \n * Gets a String's length or <code>0</code> if the String is <code>null</code>.\n * @param str a String or <code>null</code>\n * @return String length or <code>0</code> if the String is <code>null</code>.\n * @since 2.4\n */\n\npublic static int length(final String str){", "signature": "public static int length(final String str){", "docstring": "/** \n * Gets a String's length or <code>0</code> if the String is <code>null</code>.\n * @param str a String or <code>null</code>\n * @return String length or <code>0</code> if the String is <code>null</code>.\n * @since 2.4\n */\n"}
|
|
{"question_id": "636767ab1a6d9265ec018676", "input": "/** \n * Is this a hex digit?\n */\n\nprivate static boolean isHex(final char c){", "signature": "private static boolean isHex(final char c){", "docstring": "/** \n * Is this a hex digit?\n */\n"}
|
|
{"question_id": "636766f81a6d9265ec017748", "input": "/** \n * Decoding a string to a string follow the Base64 regular. \n */\n\npublic static String base64Decode(final String s){", "signature": "public static String base64Decode(final String s){", "docstring": "/** \n * Decoding a string to a string follow the Base64 regular. \n */\n"}
|
|
{"question_id": "636766f11a6d9265ec017663", "input": "/** \n * <p>Checks whether two arrays are the same length, treating <code>null</code> arrays as length <code>0</code>.</p>\n * @param array1 the first array, may be <code>null</code>\n * @param array2 the second array, may be <code>null</code>\n * @return <code>true</code> if length of arrays matches, treating<code>null</code> as an empty array\n */\n\npublic static boolean isSameLength(final double[] array1,final double[] array2){", "signature": "public static boolean isSameLength(final double[] array1,final double[] array2){", "docstring": "/** \n * <p>Checks whether two arrays are the same length, treating <code>null</code> arrays as length <code>0</code>.</p>\n * @param array1 the first array, may be <code>null</code>\n * @param array2 the second array, may be <code>null</code>\n * @return <code>true</code> if length of arrays matches, treating<code>null</code> as an empty array\n */\n"}
|
|
{"question_id": "6367667d1a6d9265ec0173ff", "input": "/** \n * Retrieve an instance of {@link Meteor} based on the {@link HttpServletRequest}.\n * @param r {@link HttpServletRequest}\n * @return a {@link Meteor} or null if not found\n */\n\npublic static Meteor lookup(HttpServletRequest r){", "signature": "public static Meteor lookup(HttpServletRequest r){", "docstring": "/** \n * Retrieve an instance of {@link Meteor} based on the {@link HttpServletRequest}.\n * @param r {@link HttpServletRequest}\n * @return a {@link Meteor} or null if not found\n */\n"}
|
|
{"question_id": "636767691a6d9265ec0181a6", "input": "/** \n * Split a String at the first occurrence of the delimiter. Does not include the delimiter in the result.\n * @param toSplit the string to split\n * @param delimiter to split the string up with\n * @return a two element array with index 0 being before the delimiter, andindex 1 being after the delimiter (neither element includes the delimiter); or <code>null</code> if the delimiter wasn't found in the given input String\n */\n\npublic static String[] split(String toSplit,String delimiter){", "signature": "public static String[] split(String toSplit,String delimiter){", "docstring": "/** \n * Split a String at the first occurrence of the delimiter. Does not include the delimiter in the result.\n * @param toSplit the string to split\n * @param delimiter to split the string up with\n * @return a two element array with index 0 being before the delimiter, andindex 1 being after the delimiter (neither element includes the delimiter); or <code>null</code> if the delimiter wasn't found in the given input String\n */\n"}
|
|
{"question_id": "636767601a6d9265ec0180e2", "input": "/** \n * Computes the global separator list of the {@code graph}. More precisely, for every edge $e$ in the $G = (V, E)$ computes list of minimal separators $S_e$ in the neighborhood of $e$ and then concatenates these lists. Note: the result may contain duplicates\n * @return the list of minimal separators of every edge $e$ in the inspected graph\n */\n\nprivate List<Pair<List<Pair<Integer,Integer>>,E>> computeGlobalSeparatorList(){", "signature": "private List<Pair<List<Pair<Integer,Integer>>,E>> computeGlobalSeparatorList(){", "docstring": "/** \n * Computes the global separator list of the {@code graph}. More precisely, for every edge $e$ in the $G = (V, E)$ computes list of minimal separators $S_e$ in the neighborhood of $e$ and then concatenates these lists. Note: the result may contain duplicates\n * @return the list of minimal separators of every edge $e$ in the inspected graph\n */\n"}
|
|
{"question_id": "636766f31a6d9265ec01768f", "input": "/** \n * <p>Clones an array returning a typecast result and handling <code>null</code>.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array the array to clone, may be <code>null</code>\n * @return the cloned array, <code>null</code> if <code>null</code> input\n */\n\npublic static char[] clone(final char[] array){", "signature": "public static char[] clone(final char[] array){", "docstring": "/** \n * <p>Clones an array returning a typecast result and handling <code>null</code>.</p> <p>This method returns <code>null</code> for a <code>null</code> input array.</p>\n * @param array the array to clone, may be <code>null</code>\n * @return the cloned array, <code>null</code> if <code>null</code> input\n */\n"}
|
|
{"question_id": "636766831a6d9265ec0174eb", "input": "/** \n * Add the specified files in reverse order.\n */\n\nprivate void addReverse(final File[] files){", "signature": "private void addReverse(final File[] files){", "docstring": "/** \n * Add the specified files in reverse order.\n */\n"}
|
|
{"question_id": "636767841a6d9265ec0183ff", "input": "/** \n * Selects a the specified row in the specified JTable and scrolls the specified JScrollpane to the newly selected row. More importantly, the call to repaint() delayed long enough to have the table properly paint the newly selected row which may be offscre\n * @param table should belong to the specified JScrollPane\n */\n\npublic static void selectRow(int row,JTable table,JScrollPane pane){", "signature": "public static void selectRow(int row,JTable table,JScrollPane pane){", "docstring": "/** \n * Selects a the specified row in the specified JTable and scrolls the specified JScrollpane to the newly selected row. More importantly, the call to repaint() delayed long enough to have the table properly paint the newly selected row which may be offscre\n * @param table should belong to the specified JScrollPane\n */\n"}
|
|
{"question_id": "636766a81a6d9265ec017596", "input": "/** \n * Puts an int into this byte vector. The byte vector is automatically enlarged if necessary.\n * @param intValue an int.\n * @return this byte vector.\n */\n\npublic ByteVector putInt(final int intValue){", "signature": "public ByteVector putInt(final int intValue){", "docstring": "/** \n * Puts an int into this byte vector. The byte vector is automatically enlarged if necessary.\n * @param intValue an int.\n * @return this byte vector.\n */\n"}
|
|
{"question_id": "636766fd1a6d9265ec017814", "input": "/** \n * Compares <code>count</code> first bytes in the arrays <code>a</code> and <code>b</code>.\n * @param a The first array to compare.\n * @param b The second array to compare.\n * @param count How many bytes should be compared.\n * @return <code>true</code> if <code>count</code> first bytes in arrays<code>a</code> and <code>b</code> are equal.\n */\n\npublic static boolean arrayequals(byte[] a,byte[] b,int count){", "signature": "public static boolean arrayequals(byte[] a,byte[] b,int count){", "docstring": "/** \n * Compares <code>count</code> first bytes in the arrays <code>a</code> and <code>b</code>.\n * @param a The first array to compare.\n * @param b The second array to compare.\n * @param count How many bytes should be compared.\n * @return <code>true</code> if <code>count</code> first bytes in arrays<code>a</code> and <code>b</code> are equal.\n */\n"}
|
|
{"question_id": "636767861a6d9265ec018440", "input": "/** \n * Abbreviate name.\n * @param buf buffer to append abbreviation.\n * @param nameStart start of name to abbreviate.\n */\n\npublic void abbreviate(final int nameStart,final StringBuffer buf){", "signature": "public void abbreviate(final int nameStart,final StringBuffer buf){", "docstring": "/** \n * Abbreviate name.\n * @param buf buffer to append abbreviation.\n * @param nameStart start of name to abbreviate.\n */\n"}
|
|
{"question_id": "6367667d1a6d9265ec01741d", "input": "/** \n * Resolves the first bound for the {@code typeVariable}, returning {@code Unknown.class} if nonecan be resolved.\n */\n\npublic static Type resolveBound(TypeVariable<?> typeVariable){", "signature": "public static Type resolveBound(TypeVariable<?> typeVariable){", "docstring": "/** \n * Resolves the first bound for the {@code typeVariable}, returning {@code Unknown.class} if nonecan be resolved.\n */\n"}
|
|
{"question_id": "6367675f1a6d9265ec0180cf", "input": "/** \n * Check whether the subgraph of <code>graph</code> induced by the given <code>vertices</code> is complete, i.e. a clique.\n * @param graph the graph.\n * @param vertices the vertices to induce the subgraph from.\n * @return true if the induced subgraph is a clique.\n */\n\nprivate static <V,E>boolean isClique(Graph<V,E> graph,Set<V> vertices){", "signature": "private static <V,E>boolean isClique(Graph<V,E> graph,Set<V> vertices){", "docstring": "/** \n * Check whether the subgraph of <code>graph</code> induced by the given <code>vertices</code> is complete, i.e. a clique.\n * @param graph the graph.\n * @param vertices the vertices to induce the subgraph from.\n * @return true if the induced subgraph is a clique.\n */\n"}
|
|
{"question_id": "636767431a6d9265ec017c88", "input": "/** \n * Finds a maximum lower bound for every key.\n * @param keys list of keys.\n * @return the computed key lower bounds.\n */\n\nprivate List<Integer> computeLowerBounds(List<K> keys){", "signature": "private List<Integer> computeLowerBounds(List<K> keys){", "docstring": "/** \n * Finds a maximum lower bound for every key.\n * @param keys list of keys.\n * @return the computed key lower bounds.\n */\n"}
|
|
{"question_id": "636766a91a6d9265ec0175c4", "input": "/** \n * Pops as many abstract types from the output frame stack as described by the given descriptor.\n * @param descriptor a type or method descriptor (in which case its argument types are popped).\n */\n\nprivate void pop(final String descriptor){", "signature": "private void pop(final String descriptor){", "docstring": "/** \n * Pops as many abstract types from the output frame stack as described by the given descriptor.\n * @param descriptor a type or method descriptor (in which case its argument types are popped).\n */\n"}
|
|
{"question_id": "636766fb1a6d9265ec0177c3", "input": "/** \n * <p>Checks whether the character is ASCII 7 bit.</p> <pre> CharUtils.isAscii('a') = true CharUtils.isAscii('A') = true CharUtils.isAscii('3') = true CharUtils.isAscii('-') = true CharUtils.isAscii('\\n') = true CharUtils.isAscii('©') = false </pre>\n * @param ch the character to check\n * @return true if less than 128\n */\n\npublic static boolean isAscii(final char ch){", "signature": "public static boolean isAscii(final char ch){", "docstring": "/** \n * <p>Checks whether the character is ASCII 7 bit.</p> <pre> CharUtils.isAscii('a') = true CharUtils.isAscii('A') = true CharUtils.isAscii('3') = true CharUtils.isAscii('-') = true CharUtils.isAscii('\\n') = true CharUtils.isAscii('©') = false </pre>\n * @param ch the character to check\n * @return true if less than 128\n */\n"}
|
|
{"question_id": "636767581a6d9265ec017fb4", "input": "/** \n * Finds a minimum lower bound for every key.\n * @param keys a list of keys.\n * @return the computed key upper bound.\n */\n\nprivate List<Integer> computeUpperBounds(List<K> keys){", "signature": "private List<Integer> computeUpperBounds(List<K> keys){", "docstring": "/** \n * Finds a minimum lower bound for every key.\n * @param keys a list of keys.\n * @return the computed key upper bound.\n */\n"}
|
|
{"question_id": "636766801a6d9265ec017487", "input": "/** \n * Encodes a string with template parameters names present, specifically the characters '{' and '}' will be percent-encoded.\n * @param s the string with zero or more template parameters names\n * @return the string with encoded template parameters names.\n */\n\npublic static String encodeTemplateNames(String s){", "signature": "public static String encodeTemplateNames(String s){", "docstring": "/** \n * Encodes a string with template parameters names present, specifically the characters '{' and '}' will be percent-encoded.\n * @param s the string with zero or more template parameters names\n * @return the string with encoded template parameters names.\n */\n"}
|
|
{"question_id": "636767531a6d9265ec017ef1", "input": "/** \n * Compare two points for equality using tolerance 1e-9.\n * @param p1 the first point\n * @param p2 the second point\n * @return whether the two points are equal or not\n */\n\npublic static boolean equals(Point2D p1,Point2D p2){", "signature": "public static boolean equals(Point2D p1,Point2D p2){", "docstring": "/** \n * Compare two points for equality using tolerance 1e-9.\n * @param p1 the first point\n * @param p2 the second point\n * @return whether the two points are equal or not\n */\n"}
|
|
{"question_id": "6367667c1a6d9265ec0173fb", "input": "/** \n * Add a {@link AtmosphereResourceEventListener}.\n * @param e an instance of AtmosphereResourceEventListener\n */\n\n@Override public AtmosphereResource addEventListener(AtmosphereResourceEventListener e){", "signature": "@Override public AtmosphereResource addEventListener(AtmosphereResourceEventListener e){", "docstring": "/** \n * Add a {@link AtmosphereResourceEventListener}.\n * @param e an instance of AtmosphereResourceEventListener\n */\n"}
|
|
{"question_id": "636767691a6d9265ec0181ac", "input": "/** \n * Apply the given relative path to the given path, assuming standard Java folder separation (i.e. \"/\" separators).\n * @param path the path to start from (usually a full file path)\n * @param relativePath the relative path to apply(relative to the full file path above)\n * @return the full file path that results from applying the relative path\n */\n\npublic static String applyRelativePath(String path,String relativePath){", "signature": "public static String applyRelativePath(String path,String relativePath){", "docstring": "/** \n * Apply the given relative path to the given path, assuming standard Java folder separation (i.e. \"/\" separators).\n * @param path the path to start from (usually a full file path)\n * @param relativePath the relative path to apply(relative to the full file path above)\n * @return the full file path that results from applying the relative path\n */\n"}
|
|
{"question_id": "636767021a6d9265ec0178bc", "input": "/** \n * Finds the first index within a String, handling <code>null</code>. This method uses {@link String#indexOf(String)}. \n */\n\npublic static int indexOf(String str,String searchStr){", "signature": "public static int indexOf(String str,String searchStr){", "docstring": "/** \n * Finds the first index within a String, handling <code>null</code>. This method uses {@link String#indexOf(String)}. \n */\n"}
|
|
{"question_id": "636766fc1a6d9265ec0177ef", "input": "/** \n * Returns a new array of Strings without null elements. Internal method used to normalize exclude lists (arrays and collections). Note that {@link Arrays#sort(Object[])} will throw an {@link NullPointerException}if an array element is <code>null</code>.\n * @param array The array to check\n * @return The given array or a new array without null.\n */\n\nstatic String[] toNoNullStringArray(Object[] array){", "signature": "static String[] toNoNullStringArray(Object[] array){", "docstring": "/** \n * Returns a new array of Strings without null elements. Internal method used to normalize exclude lists (arrays and collections). Note that {@link Arrays#sort(Object[])} will throw an {@link NullPointerException}if an array element is <code>null</code>.\n * @param array The array to check\n * @return The given array or a new array without null.\n */\n"}
|
|
{"question_id": "636767061a6d9265ec01794a", "input": "/** \n * Returns the index of the last extension separator character, which is a dot. <p> This method also checks that there is no directory separator after the last dot. To do this it uses {@link #indexOfLastSeparator(String)} which willhandle a file in either Unix or Windows format. <p> The output will be the same irrespective of the machine that the code is running on.\n * @param filename the filename to find the last path separator in, null returns -1\n * @return the index of the last separator character, or -1 if thereis no such character\n */\n\npublic static int indexOfExtension(String filename){", "signature": "public static int indexOfExtension(String filename){", "docstring": "/** \n * Returns the index of the last extension separator character, which is a dot. <p> This method also checks that there is no directory separator after the last dot. To do this it uses {@link #indexOfLastSeparator(String)} which willhandle a file in either Unix or Windows format. <p> The output will be the same irrespective of the machine that the code is running on.\n * @param filename the filename to find the last path separator in, null returns -1\n * @return the index of the last separator character, or -1 if thereis no such character\n */\n"}
|
|
{"question_id": "636767dd1a6d9265ec0186de", "input": "/** \n * @param timestamp of current time\n * @param expiredThreshold represents the duration between last update time and the time point removing from cache.\n * @return true means this metrics should be removed from cache.\n */\n\npublic boolean isExpired(long timestamp,long expiredThreshold){", "signature": "public boolean isExpired(long timestamp,long expiredThreshold){", "docstring": "/** \n * @param timestamp of current time\n * @param expiredThreshold represents the duration between last update time and the time point removing from cache.\n * @return true means this metrics should be removed from cache.\n */\n"}
|
|
{"question_id": "6367675d1a6d9265ec018082", "input": "/** \n * Returns an edge connecting previously returned node with node, which will be returned next. If either of the mentioned nodes is virtual, the edge will be incident to its real counterpart.\n * @return an edge from the current node to the next node\n */\n\nEdge edgeToNext(){", "signature": "Edge edgeToNext(){", "docstring": "/** \n * Returns an edge connecting previously returned node with node, which will be returned next. If either of the mentioned nodes is virtual, the edge will be incident to its real counterpart.\n * @return an edge from the current node to the next node\n */\n"}
|
|
{"question_id": "6367676b1a6d9265ec0181e9", "input": "/** \n * Returns {@code true} if the given string matches the given substring at the given index, {@code false} otherwise.\n * @param str the original string (or StringBuilder)\n * @param index the index in the original string to start matching against\n * @param substring the substring to match at the given index\n * @return {@code true} if the given string matches the given substring at the given index, {@code false} otherwise.\n */\n\npublic static boolean substringMatch(CharSequence str,int index,CharSequence substring){", "signature": "public static boolean substringMatch(CharSequence str,int index,CharSequence substring){", "docstring": "/** \n * Returns {@code true} if the given string matches the given substring at the given index, {@code false} otherwise.\n * @param str the original string (or StringBuilder)\n * @param index the index in the original string to start matching against\n * @param substring the substring to match at the given index\n * @return {@code true} if the given string matches the given substring at the given index, {@code false} otherwise.\n */\n"}
|
|
{"question_id": "636767781a6d9265ec01823e", "input": "/** \n * Handles a log event. For this appender, that means writing the message to each connected client. \n */\n\nprotected void append(LoggingEvent event){", "signature": "protected void append(LoggingEvent event){", "docstring": "/** \n * Handles a log event. For this appender, that means writing the message to each connected client. \n */\n"}
|
|
{"question_id": "6367670b1a6d9265ec017a05", "input": "/** \n * <p>Converts the character to a String that contains the one character.</p> <p>For ASCII 7 bit characters, this uses a cache that will return the same String object each time.</p> <pre> CharUtils.toString(' ') = \" \" CharUtils.toString('A') = \"A\" </pre>\n * @param ch the character to convert\n * @return a String containing the one specified character\n */\n\npublic static String toString(final char ch){", "signature": "public static String toString(final char ch){", "docstring": "/** \n * <p>Converts the character to a String that contains the one character.</p> <p>For ASCII 7 bit characters, this uses a cache that will return the same String object each time.</p> <pre> CharUtils.toString(' ') = \" \" CharUtils.toString('A') = \"A\" </pre>\n * @param ch the character to convert\n * @return a String containing the one specified character\n */\n"}
|
|
{"question_id": "636767a31a6d9265ec01854f", "input": "/** \n * Check if this field have been packed into a length-delimited field. If so, update internal state to reflect that packed fields are being read.\n * @throws IOException\n */\n\nprivate void checkIfPackedField() throws IOException {", "signature": "private void checkIfPackedField() throws IOException {", "docstring": "/** \n * Check if this field have been packed into a length-delimited field. If so, update internal state to reflect that packed fields are being read.\n * @throws IOException\n */\n"}
|
|
{"question_id": "636767a81a6d9265ec0185fc", "input": "/** \n * Attempt to read a field tag, returning zero if we have reached EOF. Protocol message parsers use this to read tags, since a protocol message may legally end wherever a tag occurs, and zero is not a valid tag number.\n */\n\npublic int readTag() throws IOException {", "signature": "public int readTag() throws IOException {", "docstring": "/** \n * Attempt to read a field tag, returning zero if we have reached EOF. Protocol message parsers use this to read tags, since a protocol message may legally end wherever a tag occurs, and zero is not a valid tag number.\n */\n"}
|
|
{"question_id": "636766a81a6d9265ec017595", "input": "/** \n * Puts two bytes into this byte vector. The byte vector is automatically enlarged if necessary.\n * @param byteValue1 a byte.\n * @param byteValue2 another byte.\n * @return this byte vector.\n */\n\nfinal ByteVector put11(final int byteValue1,final int byteValue2){", "signature": "final ByteVector put11(final int byteValue1,final int byteValue2){", "docstring": "/** \n * Puts two bytes into this byte vector. The byte vector is automatically enlarged if necessary.\n * @param byteValue1 a byte.\n * @param byteValue2 another byte.\n * @return this byte vector.\n */\n"}
|
|
{"question_id": "636766ae1a6d9265ec0175d8", "input": "/** \n * Build the 'Content-Range' HTTP Header value.\n * @return 'Content-Range' value\n */\n\nprivate String buildContentRange(){", "signature": "private String buildContentRange(){", "docstring": "/** \n * Build the 'Content-Range' HTTP Header value.\n * @return 'Content-Range' value\n */\n"}
|
|
{"question_id": "636767e11a6d9265ec018790", "input": "/** \n * load thread snapshots in appointing time range\n */\n\npublic static List<ThreadSnapshot> parseFromFileWithTimeRange(File file,List<ProfileAnalyzeTimeRange> timeRanges) throws IOException {", "signature": "public static List<ThreadSnapshot> parseFromFileWithTimeRange(File file,List<ProfileAnalyzeTimeRange> timeRanges) throws IOException {", "docstring": "/** \n * load thread snapshots in appointing time range\n */\n"}
|
|
|