conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "human",
"value": "Add impl of chaining signature trust engine.\n\ngit-svn-id: 46308aa6df3a13aea5930e6665b35c8b83c3a711@428 9fbd0cf9-a10c-0410-82c1-be8c084f3200\n"
},
{
"from": "gpt",
"value": "/*\r\n * Copyright [2007] [University Corporation for Advanced Internet Development, Inc.]\r... | java | chosen |
[
{
"from": "human",
"value": "Fix undertow warning about missing config\n"
},
{
"from": "gpt",
"value": "/*\n * Copyright (C) 2016-2019 Dennis Neufeld\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as pu... | java | chosen |
[
{
"from": "human",
"value": "Add device experience friendly package update observer pattern."
},
{
"from": "gpt",
"value": "package com.oasisfeng.pattern.update;\n\nimport android.content.BroadcastReceiver;\nimport android.content.ComponentName;\nimport android.content.Context;\nimport android.c... | java | chosen |
[
{
"from": "human",
"value": "Add a new trivial clustering algorithm using existing labels.\nUseful for comparing results to a golden standard.\n"
},
{
"from": "gpt",
"value": "package de.lmu.ifi.dbs.elki.algorithm.clustering;\n\nimport java.util.Collection;\nimport java.util.HashMap;\nimport jav... | java | chosen |
[
{
"from": "human",
"value": "Enable to replace an image while keeping its properties and order"
},
{
"from": "gpt",
"value": "package org.apache.poi;\n\n/**\n * This is an internal class, it should not be considered as a public API:\n * this class will be deleted without any warning.\n */\n@Depr... | java | chosen |
[
{
"from": "human",
"value": "Test class for reading from many files in parallel.\n\n"
},
{
"from": "gpt",
"value": "//\n// ParallelRead.java\n//\n\nimport java.io.File;\nimport loci.formats.ImageReader;\n\n/**\n * Reads all files in given directory in parallel,\n * using a separate thread for ea... | java | chosen |
[
{
"from": "human",
"value": "Add PeerDiscovery for getting peers from a simplified masternode list\n\nSigned-off-by: HashEngineering <cdfd0e2929fd184ec34228d20f211727fcb487d4@gmail.com>\n"
},
{
"from": "gpt",
"value": "package org.bitcoinj.net.discovery;\n\nimport org.bitcoinj.evolution.Simplifi... | java | chosen |
[
{
"from": "human",
"value": "Add custom notification utility helper\n"
},
{
"from": "gpt",
"value": "/*\n * Copyright 2015 Ryan Gilera.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtai... | java | chosen |
[
{
"from": "human",
"value": "Implement my binary search tree\n"
},
{
"from": "gpt",
"value": "package lintcode.bst;\n\nimport fundamentals.tree.TreeNode;\n\n/**\n */\npublic class MyBst {\n\n // 85-Insert Node in a Binary Search Tree\n public TreeNode insertNode(TreeNode root, TreeNode nod... | java | chosen |
[
{
"from": "human",
"value": "Add an utility to generate random arrays for algorith testing"
},
{
"from": "gpt",
"value": "\nimport java.util.ArrayList;\nimport java.util.List;\nimport java.util.Random;\n\npublic class RandomArrayGenerator {\n\n\tprivate final int size;\n\n\tprivate final int min... | java | chosen |
[
{
"from": "human",
"value": "Solve reverse a linked list\n\nThis helped: http://www.geeksforgeeks.org/write-a-function-to-reverse-the-nodes-of-a-linked-list/\n"
},
{
"from": "gpt",
"value": "/*\n Insert Node at the end of a linked list\n head pointer input could be NULL as well for empty list\... | java | chosen |
[
{
"from": "system",
"value": "Disable stdout when convert doc to docx\n"
},
{
"from": "human",
"value": "import java.io.FileInputStream;\n\nimport org.docx4j.convert.in.Doc;\nimport org.docx4j.openpackaging.packages.WordprocessingMLPackage;\n\n\npublic class DocToPDFConverter extends DocxToPDFCo... | java | chosen |
[
{
"from": "human",
"value": "Add JUnit tests for MockEc2EndpointServlet\n"
},
{
"from": "gpt",
"value": "package com.tlswe.awsmock.ec2.servlet;\n\nimport java.io.IOException;\nimport java.util.HashMap;\nimport java.util.Map;\n\nimport javax.servlet.http.HttpServletRequest;\nimport javax.servlet.... | java | chosen |
[
{
"from": "human",
"value": "Add test suite for graph classes\n"
},
{
"from": "gpt",
"value": "/*\nCopyright (c) 2014, Colorado State University\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without modification,\nare permitted provided that the following co... | java | chosen |
[
{
"from": "human",
"value": "Create test for DynamoDBService functionality\n"
},
{
"from": "gpt",
"value": "/*\n * Copyright 2016 Exorath\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obt... | java | chosen |
[
{
"from": "human",
"value": "Add shut down hook for properly shutting down the admin app\n"
},
{
"from": "gpt",
"value": "package org.pdxfinder.controllers;\n\nimport org.springframework.beans.BeansException;\nimport org.springframework.context.ApplicationContext;\nimport org.springframework.con... | java | chosen |
[
{
"from": "human",
"value": "Add tests for literal messages\n"
},
{
"from": "gpt",
"value": "/*\n * See LICENSE file in distribution for copyright and licensing information.\n */\npackage seph.lang.ast;\n\nimport org.junit.Test;\nimport static org.junit.Assert.*;\n\nimport seph.lang.SephObject;\... | java | chosen |
[
{
"from": "human",
"value": "Add \"Bio-Formats Mass Importer\" example plugin.\n\n"
},
{
"from": "gpt",
"value": "//\n// Mass_Importer.java\n//\n\nimport ij.IJ;\nimport ij.gui.YesNoCancelDialog;\nimport ij.io.DirectoryChooser;\nimport ij.plugin.PlugIn;\nimport java.io.File;\nimport java.util.Has... | java | chosen |
[
{
"from": "human",
"value": "Add monitor statistics class for json mapping\n"
},
{
"from": "gpt",
"value": "package sonata.kernel.placement.monitor;\n\nimport com.fasterxml.jackson.annotation.JsonProperty;\n\npublic class MonitorStats {\n\n /* current\n {\"NET_out\": \"648 B\", \"MEM_used\... | java | chosen |
[
{
"from": "human",
"value": "Add user and device storage\n"
},
{
"from": "gpt",
"value": "package com.github.dkanellis.fikey.storage;\n\nimport com.google.common.cache.CacheBuilder;\nimport com.google.common.cache.CacheLoader;\nimport com.google.common.cache.LoadingCache;\nimport com.yubico.u2f.... | java | chosen |
[
{
"from": "human",
"value": "Add java solution for 135. Candy\n\n135. Candy: https://leetcode.com/problems/candy/"
},
{
"from": "gpt",
"value": "package leetcode.candy;\n\nimport java.util.ArrayList;\n\npublic class Solution {\n public int candy(int[] ratings) {\n if(ratings == null ||... | java | chosen |
[
{
"from": "human",
"value": "Add a class to the sandbox\n"
},
{
"from": "gpt",
"value": "package org.jboard.jboard.sandbox;\n\npublic class Uncaught\n{\n\n\tpublic static void main(String[] args)\n\t{\n\t\tThread.currentThread().setUncaughtExceptionHandler(new Thread.UncaughtExceptionHandler()\n... | java | chosen |
[
{
"from": "human",
"value": "Add test and move easy to move methods...\n"
},
{
"from": "gpt",
"value": "package de.retest.recheck.ui.diff;\n\nimport static de.retest.recheck.ui.diff.ElementDifferenceFinder.getNonEmptyDifferences;\nimport static java.util.Collections.singletonList;\nimport static... | java | chosen |
[
{
"from": "human",
"value": "Add new package in jmetal-experimental\n"
},
{
"from": "gpt",
"value": "package org.uma.jmetal.qualityIndicator;\n\nimport org.uma.jmetal.util.VectorUtils;\nimport org.uma.jmetal.util.checking.Check;\n\n/**\n * @author Antonio J. Nebro <antonio@lcc.uma.es>\n *\n */\n... | java | chosen |
[
{
"from": "human",
"value": "Add joystick controller button tests\n"
},
{
"from": "gpt",
"value": "package com.easternedgerobotics.rov.io.joystick;\n\nimport com.easternedgerobotics.rov.test.TestEventPublisher;\nimport com.easternedgerobotics.rov.value.VideoFlipValueA;\nimport com.easternedgerob... | java | chosen |
[
{
"from": "human",
"value": "Add experimental sensor access test code"
},
{
"from": "gpt",
"value": "/**\n * \n */\npackage com.github.podd.sensors.test;\n\nimport static org.junit.Assert.*;\n\nimport java.io.ByteArrayOutputStream;\nimport java.io.IOException;\n\nimport org.junit.After;\nimport ... | java | chosen |
[
{
"from": "human",
"value": "Add a class to hold all possible tokens\n"
},
{
"from": "gpt",
"value": "package com.davidmogar.njc.syntactic;\n\nimport java.lang.reflect.Field;\n\npublic abstract class Tokens {\n\n /* Primitive types */\n public static final int CHARACTER = 257;\n public ... | java | chosen |
[
{
"from": "human",
"value": "Add credential util to store and load GlobusCredentials from files. Automatically changes permissions of file.\n\ngit-svn-id: bdb5f82b9b83a1400e05d69d262344b821646179@1380 e217846f-e12e-0410-a4e5-89ccaea66ff7\n"
},
{
"from": "gpt",
"value": "package edu.usc.glidein.u... | java | chosen |
[
{
"from": "human",
"value": "Add the BSD 2-Clause \"Simplified\" or \"FreeBSD\" license\n"
},
{
"from": "gpt",
"value": "package com.raychenon.licensedroid.license;\n\n/**\n * @author Raymond Chenon\n * https://opensource.org/licenses/BSD-2-Clause\n */\npublic class BSD2License extends LicenseIn... | java | chosen |
[
{
"from": "human",
"value": "Add basic Lint integration tests\n"
},
{
"from": "gpt",
"value": "package com.jayway.maven.plugins.android.standalonemojos;\n\nimport com.jayway.maven.plugins.android.*;\nimport io.takari.maven.testing.TestResources;\nimport io.takari.maven.testing.executor.MavenExec... | java | chosen |
[
{
"from": "human",
"value": "Add a test of ReleaseInfo\n"
},
{
"from": "gpt",
"value": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOTICE file\n * distributed with this work for additional information\n * regarding copyr... | java | chosen |
[
{
"from": "human",
"value": "Add back test for Hive dynamic filtering of partition\n"
},
{
"from": "gpt",
"value": "/*\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the Licen... | java | chosen |
[
{
"from": "human",
"value": "Add translation utility class.\nAdds method to build a URI for Google Translate."
},
{
"from": "gpt",
"value": "package cgeo.geocaching.utils;\n\nimport java.net.URLEncoder;\n\n/**\n * Utilities used for translating\n */\npublic final class TranslationUtils {\n\n ... | java | chosen |
[
{
"from": "human",
"value": "Add a getOnlinePlayers() that support both old and new ones"
},
{
"from": "gpt",
"value": "package io.github.Cnly.Crafter.Crafter.utils;\n\nimport java.lang.reflect.InvocationTargetException;\nimport java.lang.reflect.Method;\nimport java.util.Arrays;\nimport java.ut... | java | chosen |
[
{
"from": "human",
"value": "Add Java test for encoding service (only for testing)."
},
{
"from": "gpt",
"value": "/**\n * Copyright (C) 2016 Joshua Auerbach \n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the Lic... | java | chosen |
[
{
"from": "human",
"value": "Test for checking that all configured (in the annotations) sequences for oracle are less than 30 characters\n"
},
{
"from": "gpt",
"value": "package edu.northwestern.bioinformatics.studycalendar.domain;\n\nimport edu.northwestern.bioinformatics.studycalendar.testing.... | java | chosen |
[
{
"from": "human",
"value": "Add timing class to evaluate the preprocessor performance on a large synthesized dataset\n"
},
{
"from": "gpt",
"value": "package edu.ntnu.idi.goldfish;\n\nimport edu.ntnu.idi.goldfish.configurations.Config;\nimport edu.ntnu.idi.goldfish.configurations.Lynx;\nimport ... | java | chosen |
[
{
"from": "human",
"value": "Solve PHONELST for practice of tries\n"
},
{
"from": "gpt",
"value": "// Author: Param Singh <paramsingh258@gmail.com>\n// http://www.spoj.com/problems/PHONELST/\n\nimport java.io.*;\nclass Trie {\n private class Node {\n Node children[];\n boolean f... | java | chosen |
[
{
"from": "human",
"value": "Add a unit test for MixServer"
},
{
"from": "gpt",
"value": "/*\n * Hivemall: Hive scalable Machine Learning Library\n *\n * Copyright (C) 2013-2014\n * National Institute of Advanced Industrial Science and Technology (AIST)\n * Registration Number: H25PRO-1520\n... | java | chosen |
[
{
"from": "human",
"value": "Add a delegating authenticator which can be used to map different authenticators to different URIs (JENA-480)\n\ngit-svn-id: bc509ec38c1227b3e85ea1246fda136342965d36@1498721 13f79535-47bb-0310-9956-ffa450edef68\n"
},
{
"from": "gpt",
"value": "/*\n * Licensed to the ... | java | chosen |
[
{
"from": "human",
"value": "Add runner to verify multi-receiver support of habitat API."
},
{
"from": "gpt",
"value": "package nl.sikken.bertrik.hab.habitat;\n\nimport java.time.Duration;\nimport java.time.Instant;\nimport java.util.Arrays;\n\nimport nl.sikken.bertrik.hab.Sentence;\n\npublic fi... | java | chosen |
[
{
"from": "human",
"value": "Create new executor to handle resource pools\n"
},
{
"from": "gpt",
"value": "package client.shareserver;\n\nimport java.util.ArrayList;\nimport java.util.List;\nimport java.util.concurrent.AbstractExecutorService;\nimport java.util.concurrent.Callable;\nimport java.... | java | chosen |
[
{
"from": "human",
"value": "Allow multiple independent random walks for different indices of the same parameter."
},
{
"from": "gpt",
"value": "package dr.inference.operators;\r\n\r\nimport dr.inference.model.Parameter;\r\nimport dr.math.MathUtils;\r\nimport dr.xml.*;\r\n\r\n/**\r\n * @author C... | java | chosen |
[
{
"from": "human",
"value": "Add solution for problem Java Static Initializer Block\n\nJava Static Initializer Block from HackerRank/Introduction/Java Static Initializer Block\n"
},
{
"from": "gpt",
"value": "package javaStaticInitializerBlock;\n\nimport java.util.Scanner;\n\npublic class Soluti... | java | chosen |
[
{
"from": "human",
"value": "Add simple package info file\n"
},
{
"from": "gpt",
"value": "/*\n * The MIT License\n *\n * Copyright 2017 Fernando van Loenhout.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation f... | java | chosen |
[
{
"from": "human",
"value": "Implement data repository for user account\n"
},
{
"from": "gpt",
"value": "/*\n * Copyright (c) 2015 Ushahidi Inc\n *\n * This program is free software: you can redistribute it and/or modify it under\n * the terms of the GNU Affero General Public License as publish... | java | chosen |
[
{
"from": "human",
"value": "Add HTTP transport, scratch for now\n"
},
{
"from": "gpt",
"value": "package org.cstamas.vertx.content.impl;\n\nimport io.vertx.core.Vertx;\nimport io.vertx.core.buffer.Buffer;\nimport io.vertx.core.http.HttpClient;\nimport io.vertx.core.http.HttpServer;\nimport io.v... | java | chosen |
[
{
"from": "human",
"value": "Create a test for geometry collection\n"
},
{
"from": "gpt",
"value": "package fgis.server.support.geojson;\n\nimport java.util.Arrays;\nimport org.testng.annotations.Test;\nimport static org.testng.Assert.*;\n\npublic final class GjGeometryCollectionTest\n extends ... | java | chosen |
[
{
"from": "human",
"value": "Add basic impl for total counts\n"
},
{
"from": "gpt",
"value": "/*\n * Copyright 2016 Timothy Brooks\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a c... | java | chosen |
[
{
"from": "human",
"value": "Add a user's friendship status request\n"
},
{
"from": "gpt",
"value": "/**\n * Copyright (C) 2016 Bruno Candido Volpato da Cunha (brunocvcunha@gmail.com)\n * <p>\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file exce... | java | chosen |
[
{
"from": "human",
"value": "Check for create form for all account registration wizards before sending the user to the web registration page.\n"
},
{
"from": "gpt",
"value": "/*\n * SIP Communicator, the OpenSource Java VoIP and Instant Messaging client.\n *\n * Distributable under LGPL license.... | java | chosen |
[
{
"from": "human",
"value": "XWIKI-13528: Add support for replacing the default WYSIWYG editor\n* We need to be able to edit the raw wiki syntax and for this we need a new data type (besides XDOM)\n"
},
{
"from": "gpt",
"value": "/*\n * See the NOTICE file distributed with this work for addition... | java | chosen |
[
{
"from": "human",
"value": "Test for the binary file recording\n"
},
{
"from": "gpt",
"value": "package edu.oregonstate.cope.eclipse.listeners;\n\nimport static org.junit.Assert.assertTrue;\n\nimport java.io.BufferedInputStream;\nimport java.io.ByteArrayInputStream;\nimport java.util.Arrays;\ni... | java | chosen |
[
{
"from": "human",
"value": "Test Application for HTTP API\n\n\nSVN-Revision: 2577\n"
},
{
"from": "gpt",
"value": "import java.io.ObjectInputStream;\r\nimport java.io.ObjectOutputStream;\r\nimport java.net.URL;\r\nimport java.net.URLConnection;\r\nimport java.util.Iterator;\r\n\r\nimport org.ap... | java | chosen |
[
{
"from": "human",
"value": "Update after organising some files\n"
},
{
"from": "gpt",
"value": "public class findMode{\n public static void main(String[] args){\n\n }\n public static int mode(int[] array){\n ArrayList<Integer> r = new ArrayList<>();\n\n }\n public static i... | java | chosen |
[
{
"from": "human",
"value": "Add java solution for 242. Valid Anagram\n\n242. Valid Anagram: https://leetcode.com/problems/valid-anagram/"
},
{
"from": "gpt",
"value": "package leetcode.valid_anagram;\n\npublic class Solution {\n public boolean isAnagram(String s, String t) {\n if(s.le... | java | chosen |
[
{
"from": "human",
"value": "Add code for Twist in the Tale 2.2\n"
},
{
"from": "gpt",
"value": "/**\n * Twist in the Tale 2.2 from the OCA Java SE 7 book by Mala Gupta (Manning Publications)\n * Created by Josef on 12/17/13.\n */\npublic class TwistInTheTale2_2 {\n static void main (String[]... | java | chosen |
[
{
"from": "human",
"value": "Add unit test for ReflectUtil.newInstanceOf\n"
},
{
"from": "gpt",
"value": "package com.poiji.util;\n\nimport static org.junit.Assert.assertNotNull;\nimport static org.junit.Assume.assumeTrue;\n\nimport java.lang.reflect.ReflectPermission;\n\nimport org.junit.Before... | java | chosen |
[
{
"from": "human",
"value": "Add a terminal type that just uses the console.\n\ngit-svn-id: c55cfc7c8893d43c3333f2d886128b43c8520716@380518 13f79535-47bb-0310-9956-ffa450edef68\n"
},
{
"from": "gpt",
"value": "package org.xbean.terminal.console;\n\nimport org.xbean.command.CommandShell;\n\npubli... | java | chosen |
[
{
"from": "human",
"value": "Add test cases for LaunchTask\n"
},
{
"from": "gpt",
"value": "/**\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOTICE file\n * distributed with this work for additional information\n * regarding ... | java | chosen |
[
{
"from": "human",
"value": "GUAC-1345: Add simple property type which parses to a set of strings."
},
{
"from": "gpt",
"value": "/*\n * Copyright (C) 2015 Glyptodon LLC\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated docum... | java | chosen |
[
{
"from": "human",
"value": "Add default implementation of Raster interface.\n"
},
{
"from": "gpt",
"value": "package net.imagej.ops.viewOp;\n\nimport org.scijava.plugin.Plugin;\n\nimport net.imagej.ops.view.ViewOps;\nimport net.imagej.ops.view.ViewOps.Raster;\nimport net.imglib2.RealRandomAcces... | java | chosen |
[
{
"from": "human",
"value": "Test the visibility check itself\n"
},
{
"from": "gpt",
"value": "package com.kaching.platform.testing;\n\nimport static com.kaching.platform.testing.VisibilityTestRunner.Intent.PRIVATE;\nimport static org.junit.Assert.*;\n\nimport org.junit.Test;\n\npublic class Vis... | java | chosen |
[
{
"from": "human",
"value": "Camel-AWS: Create single Karaf feature tests for single components, aws-ecs test\n"
},
{
"from": "gpt",
"value": "/**\n * Licensed to the Apache Software Foundation (ASF) under one or more\n * contributor license agreements. See the NOTICE file distributed with\n * ... | java | chosen |
[
{
"from": "human",
"value": "Test for validation of Reference values for annotation filtering.\n"
},
{
"from": "gpt",
"value": "package uk.ac.ebi.quickgo.annotation.validation;\n\nimport org.springframework.context.annotation.Bean;\nimport org.springframework.context.annotation.Configuration;\n\... | java | chosen |
[
{
"from": "human",
"value": "Create a new exception that people can throw if they know they want it to go to the outside world without any further need for DWR configuration\n\ngit-svn-id: b371d604c7577be4609d70acd88b8a3995ce0a58@2054 3a8262b2-faa5-11dc-8610-ff947880b6b2\n"
},
{
"from": "gpt",
"... | java | chosen |
[
{
"from": "human",
"value": "Add do-nothing double-to-double outcome encoder. Necessary for regression.\n\ngit-svn-id: 34a63cff78c965ed7296912184cd0e3b6b7dc1c0@2899 2f4ce1e4-9571-11dd-93b2-6d14b300b761\n"
},
{
"from": "gpt",
"value": "/* \n * Copyright (c) 2011, Regents of the University of Colo... | java | chosen |
[
{
"from": "human",
"value": "Test case for the array toString() detector\n\ngit-svn-id: e7d6bde23f017c9ff4efd468d79d66def666766b@9118 eae3c2d3-9b19-0410-a86e-396b6ccb6ab3\n"
},
{
"from": "gpt",
"value": "\npublic class ArrayToString {\n\t\n\tprivate static final String[] gargs = new String[] {\"... | java | chosen |
[
{
"from": "human",
"value": "[Java] Print Java-related ENV and system properties.\n"
},
{
"from": "gpt",
"value": "package io.aeron;\n\nimport org.junit.jupiter.api.Test;\n\nclass PrintEnvInfo\n{\n @Test\n void test()\n {\n System.out.println(\"=========================\");\n ... | java | chosen |
[
{
"from": "human",
"value": "Add regression test. See ticket:39.\n\nSigned-off-by: Etienne M. Gagnon <bf06ec0eb40152cd863534753d026b021022c851@j-meg.com>\n"
},
{
"from": "gpt",
"value": "/* This file is part of SableCC ( http://sablecc.org ).\n * \n * See the NOTICE file distributed with this wo... | java | chosen |
[
{
"from": "human",
"value": "Add unit test for event handler\n"
},
{
"from": "gpt",
"value": "package com.semation.jstatsd.server.messaging.disruptor;\n\nimport com.lmax.disruptor.EventHandler;\nimport com.semation.jstatsd.StatsMessage;\nimport org.junit.Test;\n\nimport static org.easymock.EasyM... | java | chosen |
[
{
"from": "human",
"value": "Add a small utility to track fair gas price\n"
},
{
"from": "gpt",
"value": "package org.ethereum.listener;\n\nimport org.ethereum.core.TransactionExecutionSummary;\n\nimport java.util.Arrays;\n\n/**\n * Calculates a 'reasonable' Gas price based on statistics of the ... | java | chosen |
[
{
"from": "human",
"value": "Add unit test for device message serialization\n\nThere was a test for the deserialization, but not for the serialization.\n"
},
{
"from": "gpt",
"value": "package com.genymobile.scrcpy;\n\nimport org.junit.Assert;\nimport org.junit.Test;\n\nimport java.io.ByteArrayO... | java | chosen |
[
{
"from": "human",
"value": "Add specific Exception for Render Problems\n"
},
{
"from": "gpt",
"value": "package de.interseroh.report.exception;\n\n/**\n * @author Ingo Düppe (Crowdcode)\n */\npublic class RenderReportException extends BirtReportException {\n\n\tpublic RenderReportException(Stri... | java | chosen |
[
{
"from": "human",
"value": "Add a unit test for the DefaultScriptService\n\nFor now we just test that the scijava.scripts.path system property is\nhandled as expected.\n"
},
{
"from": "gpt",
"value": "/*\n * #%L\n * SciJava Common shared library for SciJava software.\n * %%\n * Copyright (C) 20... | java | chosen |
[
{
"from": "human",
"value": "Add test of legacy Tag object\n"
},
{
"from": "gpt",
"value": "package hudson.plugins.git;\n\nimport org.eclipse.jgit.lib.ObjectId;\nimport org.junit.Before;\nimport org.junit.Test;\nimport static org.junit.Assert.*;\n\npublic class TagTest {\n private final Strin... | java | chosen |
[
{
"from": "human",
"value": "Add basic transacted sender example"
},
{
"from": "gpt",
"value": "/*\n *\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOTICE file\n * distributed with this work for additional information\n * reg... | java | chosen |
[
{
"from": "human",
"value": "Add interface for organization resolver\n"
},
{
"from": "gpt",
"value": "/*\n * Copyright (c) 2021, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in ... | java | chosen |
[
{
"from": "human",
"value": "[ALIEN-2717] Check usage of location modifiers to prevent disabling a plugin that is actually in use.\n"
},
{
"from": "gpt",
"value": "package org.alien4cloud.alm.deployment.configuration.flow;\n\nimport java.util.List;\n\nimport javax.annotation.Resource;\n\nimport ... | java | chosen |
[
{
"from": "human",
"value": "Split input triples into groups."
},
{
"from": "gpt",
"value": "/**\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * ... | java | chosen |
[
{
"from": "human",
"value": "Add 3PID medium type enum\n"
},
{
"from": "gpt",
"value": "/*\n * matrix-java-sdk - Matrix Client SDK for Java\n * Copyright (C) 2017 Maxime Dor\n *\n * https://max.kamax.io/\n *\n * This program is free software: you can redistribute it and/or modify\n * it under th... | java | chosen |
[
{
"from": "human",
"value": "Add test file for array functionality\n"
},
{
"from": "gpt",
"value": "class Foo\n{\n public static void main(String[] args)\n {\n System.out.println(new Derp().foo());\n }\n}\n\nclass Derp\n{\n public int foo()\n {\n int[] xs;\n i... | java | chosen |
[
{
"from": "human",
"value": "Add a simple manual test of scifio-bf-compat\n\nThis test can be fleshed out later to verify additional features are\nworking correctly, and/or converted to unit tests as time permits.\n"
},
{
"from": "gpt",
"value": "/*\n * #%L\n * SCIFIO Bio-Formats compatibility f... | java | chosen |
[
{
"from": "human",
"value": "Add test for GH-782 fix\n"
},
{
"from": "gpt",
"value": "/*\n * Copyright 2015 the original author or authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may o... | java | chosen |
[
{
"from": "human",
"value": "Add test to override programmatic definition from system properties.\n\nfixes #45"
},
{
"from": "gpt",
"value": "package org.springframework.cloud.localconfig;\n\nimport static org.junit.Assert.assertEquals;\nimport static org.junit.Assert.assertNotNull;\nimport stat... | java | chosen |
[
{
"from": "human",
"value": "Add direct executor which nukes threadlocals after the task is complete\n\ngit-svn-id: 56d4294a9e7c8b1ae21491ba4491dfc41c8d890d@91588 84be2c1e-ba19-0410-b317-a758671a6fc1\n"
},
{
"from": "gpt",
"value": "package org.jboss.threads;\n\nimport java.lang.reflect.Field;\n... | java | chosen |
[
{
"from": "human",
"value": "Add unit test for reference field parsing\n"
},
{
"from": "gpt",
"value": "package com.yahoo.searchdefinition.processing;\n\nimport com.yahoo.document.DataType;\nimport com.yahoo.document.Field;\nimport com.yahoo.searchdefinition.Search;\nimport com.yahoo.searchdefin... | java | chosen |
[
{
"from": "human",
"value": "Add helper to find project ignore file\n"
},
{
"from": "gpt",
"value": "package de.retest.recheck.ignore;\n\nimport java.nio.file.Path;\nimport java.util.Optional;\n\nimport de.retest.recheck.configuration.ProjectConfigurationUtil;\n\npublic class RecheckIgnoreUtil {... | java | chosen |
[
{
"from": "human",
"value": "Add ternary operator to code that can be generated\n"
},
{
"from": "gpt",
"value": "package org.jcodegen.java;\n\npublic class TernaryOperator extends Expression<TernaryOperator> {\n\n private final Condition condition;\n private final StringOrCode<Expression> ... | java | chosen |
[
{
"from": "human",
"value": "Add Anyxml normalized node to yang-data-api.\n\nProposal of anyxml normalized node interface.\nThis interface wraps Simple/CompositeNode as inner value.\n\nChange-Id: Ic9c17fa28bc5eb23288162a735d890b4f77938f1\nSigned-off-by: Maros Marsalek <a544a3532fb445ec334131e35bc3fd119321de... | java | chosen |
[
{
"from": "human",
"value": "Add tests where there were none\n"
},
{
"from": "gpt",
"value": "package com.lithium.flow.util;\n\nimport static org.junit.Assert.assertEquals;\nimport static org.junit.Assert.assertNotNull;\nimport static org.junit.Assert.fail;\n\nimport java.util.ArrayList;\n\nimpo... | java | chosen |
[
{
"from": "human",
"value": "Add test for Geoserver bean\n"
},
{
"from": "gpt",
"value": "package org.geoserver.shell;\n\nimport static org.junit.Assert.assertEquals;\nimport static org.junit.Assert.assertNull;\nimport org.junit.Test;\n\npublic class GeoserverTest {\n\n @Test\n public void... | java | chosen |
[
{
"from": "human",
"value": "feat: Create mock class to IChuckNorrisDatabase interface.\n\nSummary:\nThe mock is required so the Google Cloud server does not have wait for\nthe HTTP GET result.\n"
},
{
"from": "gpt",
"value": "/*\n * Copyright 2015 JP Ventura\n *\n * Licensed under the Apache Li... | java | chosen |
[
{
"from": "human",
"value": "[TACHYON-964] Add a class to build shell command to string\n"
},
{
"from": "gpt",
"value": "/*\n * Licensed to the University of California, Berkeley under one or more contributor license\n * agreements. See the NOTICE file distributed with this work for additional i... | java | chosen |
[
{
"from": "human",
"value": "Create service request controll filter.\n"
},
{
"from": "gpt",
"value": "package com.github.aureliano.verbum_domini.web.filter;\n\nimport java.io.IOException;\n\nimport javax.servlet.Filter;\nimport javax.servlet.FilterChain;\nimport javax.servlet.FilterConfig;\nimpo... | java | chosen |
[
{
"from": "human",
"value": "Add example of how to use the sub-resolution API\n"
},
{
"from": "gpt",
"value": "//\n// SubResolutionExample.java\n//\n\nimport java.io.IOException;\n\nimport loci.formats.FormatException;\nimport loci.formats.IFormatReader;\nimport loci.formats.ImageReader;\n\n/**\... | java | chosen |
[
{
"from": "human",
"value": "Add basic test for strategy defaults\n"
},
{
"from": "gpt",
"value": "package de.retest.recheck;\n\nimport static org.assertj.core.api.Assertions.assertThat;\n\nimport org.junit.jupiter.api.Test;\n\nimport de.retest.recheck.persistence.FileNamer;\n\nclass FileNamerSt... | java | chosen |
[
{
"from": "human",
"value": "Move no-op user manager to core from local"
},
{
"from": "gpt",
"value": "package org.owasp.appsensor.response;\n\nimport org.owasp.appsensor.AppSensorServer;\nimport org.owasp.appsensor.User;\nimport org.owasp.appsensor.configuration.ExtendedConfiguration;\nimport o... | java | chosen |
[
{
"from": "human",
"value": "Test of using properties file for NLS messages.\n"
},
{
"from": "gpt",
"value": "/*\n * $Id$\n */\n\npackage au.id.chenery.mapyrus;\n\nimport java.util.ResourceBundle;\n\n/**\n * Wrapper around a java resource file containing messages for various\n * locales. Provid... | java | chosen |
[
{
"from": "human",
"value": "Add a stomp frame translator"
},
{
"from": "gpt",
"value": "/**\n * Licensed to the Apache Software Foundation (ASF) under one or more\n * contributor license agreements. See the NOTICE file distributed with\n * this work for additional information regarding copyrig... | java | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.