query stringlengths 8 1.54M | document stringlengths 9 312k | negatives listlengths 19 20 | metadata dict |
|---|---|---|---|
Checks if the threshold for the number of incomming messages is reached. | public boolean thresholdReached() {
return mQueue.size() < sThreshold;
} | [
"boolean hasMaxIncomingConnections();",
"public boolean condition() {\n\t\treturn getMessages() >= 1;\n\t}",
"private void checkDeviceLimitReached() {\r\n try {\r\n if (explicitWaitForVisibilityOfElement(getObjectBy(\"dp.headingDeviceLimitReached\"))) {\r\n isDeviceLimitReached=... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ access modifiers changed from: private | public static boolean isFactory(PackageInfo packageInfo) {
return (packageInfo.applicationInfo.flags & 1) != 0;
} | [
"@Override\n }",
"protected void method_5557() {}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n public void publicando() {\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"private InternalReflect() {\n\t\t\t// do nothing\n\t\t}",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the bookmaker id. | String getBookmakerId(); | [
"java.lang.String getBookerID();",
"public long getBookId() {\n return bookId_;\n }",
"public java.lang.String getBookId() {\n java.lang.Object ref = bookId_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteS... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
string creator = 1; | java.lang.String getCreator(); | [
"public void setCreator(String aStr)\n {\n addInfoDictValue(\"Creator\", aStr);\n }",
"public String getCreator() {\n return creator;\n }",
"@DISPID(149) //= 0x95. The runtime will prefer the VTID if present\r\n @VTID(20)\r\n int creator();",
"Crime(String creatorName){\n\t\tthis.cr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
enable our sensor when the activity is resumed, ask for 10 ms updates. | public void start() {
mSensorManager.registerListener(this, mlinear_accelometer, 10000);
} | [
"@Override\n public void onResume() {\n super.onResume();\n sensorManager.registerListener(listener,sensor,SensorManager.SENSOR_DELAY_NORMAL);\n handler.postDelayed(turnOn,20000);\n }",
"@Override\n protected void onResume() {\n super.onResume();\n if (sensorObj != null... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get all online users | Object onlineUser() throws Exception; | [
"public List getAllUsers();",
"private String getOnlineUsers() {\n\t\tString[] users = sync.getUsers();\n\t\tStringBuilder sb = new StringBuilder();\n\t\tusersLogedIn = new HashSet<String>(); \n\t\tfor(String user : users) {\n\t\t\tif(user != this.clientName) {\n\t\t\t\tusersLogedIn.add(user);\n\t\t\t\tString use... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the motor working state. | public int get_motorState() throws YAPI_Exception
{
int res;
synchronized (this) {
if (_cacheExpiration <= YAPIContext.GetTickCount()) {
if (load(_yapi._defaultCacheValidity) != YAPI.SUCCESS) {
return MOTORSTATE_INVALID;
}
}... | [
"private RobotStatus getRobotState() {\n\t\treturn robot.getRobotStatus().get(robot.getID());\n\t}",
"public String getDesiredState() {\n return desiredState;\n }",
"public RobotStates getState() {\n return state;\n }",
"public double driveMotorStatus() {\n return wranglerDriveMotor.getMo... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set the default value of this control, it will be override by current value. | public void setValue(String defaultValue) {
((FormComboboxElement) mElement).setFormValueAttribute(defaultValue);
} | [
"protected abstract void setDefaultValue();",
"@Override\n\tpublic void setValueDefault() {\n\t\tObject defaultValue ;\n\t\tdefaultValue = items.attribute.defaultvalue; \n\t\t///如果默认值不为空,则直接加默认值\n\t\tif (defaultValue != null && !StringUtil.isNullOrEmpty(defaultValue.toString()))\n \t\t {\n\t\t\tsetValue( defau... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Testing the Java Calendar Functions | public static void testCal() {
Calendar calendar = Calendar.getInstance();
int dayOfYear = calendar.get(Calendar.DAY_OF_YEAR);
System.out.println(dayOfYear);
Calendar cal = Calendar.getInstance();
cal.set(2017, 5, 10);
System.out.println("APRIL 10th " + cal.get(Calendar.DAY_OF_YEAR));
} | [
"@Test\n public void testGetCalendarInstance() {\n System.out.println(\"getCalendarInstance\");\n Weblog instance = cut;\n Calendar expResult = Calendar.getInstance(TimeZone.getTimeZone(\"America/Los_Angeles\"), new Locale(\"en\", \"US\"));\n //expResult.set(2017, 1, 1, 0, 0, 0);\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructor that sets user, service and time | public Event (String user, String service, Date time) {
_user = user;
_service = service;
_time = time == null ? new Date() : time;
_input = "";
_output = "";
_address = "";
_status = STATUS_CREATED;
_lastStatusChange = new Date();
} | [
"public UserInfoService() {\n super();\n }",
"public UserSystem(String email, String senha) {\n super(email, senha);\n //this.senha = senha;\n online = false;\n contTentativaAcesso = 0;\n }",
"public Client(int a, int s) {\n\t\tthis.arrivalTime = a;\n\t\tthis.serviceTime = s;\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Check name of product is correct. | private static boolean isNameValid(String name) {
return name.matches(NAME_REGEX);
} | [
"private boolean isValidName(String productName) {\n return (productName.length() >= NAME_MIN_LENGTH) &&\n (productName.length() <= NAME_MAX_LENGTH) &&\n (productName.matches(\"^[a-zA-Z0-9À-ÖØ-öø-įĴ-őŔ-žǍ-ǰǴ-ǵǸ-țȞ-ȟȤ-ȳɃɆ-ɏḀ-ẞƀ-ƓƗ-ƚƝ-ơƤ-ƥƫ-ưƲ-ƶẠ-ỿ '#,.&()-]+$\"));\n }",
"pub... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Adds customers to the database, after checking values entered are valid | @FXML
void addCustomer() {
DBAction dbAction = new DBAction();
if (fnameField.getText().contains("'") || lnameField.getText().contains("'") ||
emailField.getText().contains("'")) {//cannot contain ' as it breaks DB statements
Alert alert = new Alert(Alert.AlertType.E... | [
"public void addCustomer() throws SQLException {\r\n if (!customerNameTextField.getText().equals(\"\") && !customerAddressTextField.getText().equals(\"\") &&\r\n !customerCountryComboBox.getValue().equals(\"\") && !customerFirstLevelDivisionComboBox.getValue().equals(\"\") &&\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Page Instantiations HelperMethods myHelper = new HelperMethods(driver); | public void enterPin(String firstNumber, String secondNumber, String thirdNumber, String fourthNumber) throws Exception {
PinScreen myPin = new PinScreen(driver);
MenuScreen myMenuScreen = new MenuScreen(driver);
Thread.sleep(4000);
checkForAlertsBeforePin();
dismissWhatsNewPa... | [
"public DriverHelper() {\n /**initialise the page factory in the constructor method and assign to driver level*/\n PageFactory.initElements(driver, this);\n }",
"private static void testHelper() {\n }",
"public HomePage(WebDriver ldriver ) {\r\n\t\t\r\nthis.driver= ldriver;\r\n}",
"public ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end synpred9_Meteor $ANTLR start synpred10_Meteor | public final void synpred10_Meteor_fragment() throws RecognitionException {
// /home/arv/workspace/stratosphere-sopremo/meteor/meteor-meteor/src/main/java/eu/stratosphere/meteor/Meteor.g:183:6: ( pathSegment )
// /home/arv/workspace/stratosphere-sopremo/meteor/meteor-meteor/src/main/java/eu/stratosphere/meteor/Mete... | [
"public final void synpred12_Meteor_fragment() throws RecognitionException {\n // /home/arv/workspace/private/meteor/meteor-meteor/src/main/java/eu/stratosphere/meteor/Meteor.g:182:6: ( ID ':' )\n // /home/arv/workspace/private/meteor/meteor-meteor/src/main/java/eu/stratosphere/meteor/Meteor.g:182:7: ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Metodo para almacenar un pqr nuevo | public boolean realiarPqr(Usuario usuario,String tipo, String descripcion) throws ServiceException, DaoException{
if(usuario==null){
throw new ServiceException("usuario no valido");
}
if(Validaciones.isTextoVacio(tipo)){
throw new ServiceException("Tipo de solicitud vacio");
}
if(Validaciones.isTextoVac... | [
"public String generateQRString(){\n String aux = corrigeCodigo(getAmuleto().getCodigo()+\"\"); //coloca o amuleto 4\n aux+= corrigeCodigo(getAnel1().getCodigo()+\"\"); //coloca o anel 1 8\n aux+= corrigeCodigo(getAnel2().getCodigo()+\"\"); //coloca o anel 2 12\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ renamed from: com.ss.android.ugc.aweme.music.adapter.c | public interface C33743c {
/* renamed from: a */
void mo62046a(MusicCollectionItem musicCollectionItem);
} | [
"public ArrayList<Songs> getSongsFromPhone() {\n ArrayList<Songs> arrayList = new ArrayList();\n Context context = myActivity.getApplicationContext();\n contentResolver = context.getContentResolver();\n uri = MediaStore.Audio.Media.EXTERNAL_CONTENT_URI;\n String selection = MediaS... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This function to resize image in screen with image in mode (960x640). | protected void resizeView(View view, int left, int top, int right,
int bottom) {
// function to set layout and margin for a view
RelativeLayout.LayoutParams prView = new RelativeLayout.LayoutParams(
Math.round(view.getLayoutParams().width
* calResize.getRatioResizeWidth()), Math.round(view
.getLa... | [
"@Override\r\n public void setScreenDimension(int width, int height) {\n height = Math.min(height, maximumSize);\r\n width = Math.min(width, maximumSize);\r\n if (isStereoDouble())\r\n width = (width + 1) / 2;\r\n if (dimScreen.width == width && dimScreen.height == height)\r\n return;\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
FirefoxDriver wd; wd = new FirefoxDriver(); obj.manage().timeouts().implicitlyWait(60, TimeUnit.SECONDS); obj.get(" | public void roktDailogClosing(WebDriver obj) throws Exception {
obj.findElement(By.id("rl__roktAppsBanner213659633")).click();
obj = (FirefoxDriver) obj.switchTo().frame(0);
if (!obj.findElement(By.xpath("//div[3]/div/div/div[3]/div/div/div/div/div/form/div[1]/div/div/div[3]/div[1]/div[3]/div/div... | [
"@Before\n public void startBrowser (){\n driver= new FirefoxDriver();\n\n\n driver.manage().timeouts().implicitlyWait(3, TimeUnit.SECONDS);\n }",
"@Test\n void testWithRemoteFirefox(RemoteWebDriver driver) throws InterruptedException {\n open(\"https://google.com/\");\n $(By.... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
getting details from the register page | @Override
public void onClick(View view) {
final String txt_name=name.getEditText().getText().toString();
final String txt_contact=contact.getEditText().getText().toString();
final String txt_address=address.getEditText().getText().toString();
... | [
"public void getRegInfo(){\n\t\tSystem.out.println(\"----->> New Customer Registration <<----\");\n\t\tfirstName=marketView.getFirstName();\n\t\tlastName=marketView.getLastName();\n\t\tloginId=marketView.getInputLoginId();\n\t\tpassword=marketView.getInputLoginPwd();\n\n\t\t//exception handling block\n\t\ttry{\n\t\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO: 23.03.2020 smart strategy | private void movePC(char[][] tab) {
int len = tab.length;
for (int i = 0; i < len; i++) {
for (int j = 0; j < len; j++) {
if (tab[i][j] == EMPTY) {
tab[i][j] = DOT_O;
printTab(tab);
return;
}
... | [
"@Override\n public void extornar() {\n \n }",
"protected void method_5557() {}",
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"private static void EX5() {\n\t\t\r\n\t}",
"@Override\n\t\tprotected void swop() {\n\n\t\t}",
"@Override\n p... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test case number: 79 /Coverage entropy=0.5833945029417364 | @Test(timeout = 4000)
public void test079() throws Throwable {
StringReader stringReader0 = new StringReader("~}mQAuq[?3l");
JavaCharStream javaCharStream0 = new JavaCharStream(stringReader0);
JavaParserTokenManager javaParserTokenManager0 = new JavaParserTokenManager(javaCharStream0);
javaP... | [
"@Test(timeout = 4000)\n public void test147() throws Throwable {\n TextDirectoryLoader textDirectoryLoader0 = new TextDirectoryLoader();\n Instances instances0 = textDirectoryLoader0.getStructure();\n Evaluation evaluation0 = new Evaluation(instances0, (CostMatrix) null);\n String string0 = ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | public static void main(String[] args) {
int a = 10;
int b= 20;
if (a>b)
{
System.out.println ("a is greater then b");
}else
System.out.println("b is greater then a");
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Represents a mapping of logical character identifiers to actual glyphs in a certain font. A logical character identifier (LCI) is a tag of some kind which identifies the essential aspects of a character as perceived by a reader, regardless of specific details which may be font dependent. The code points defined in the ... | public interface CharacterCodeMap {
/**
* Indicates whether or not this implementation of <code>CharacterCodeMap</code>
* defines the given <code>int</code> LCI.
* @param lci the logical character identifier
* @return <code>true</code> if this instance of <code>CharacterCodeMap</code> may contai... | [
"public int getGlyphId(int characterCode) {\n\t}",
"private static Map<Character, Byte> initializeCharacterToByteMap() {\n Map<Character, Byte> characterToByteMap = new HashMap<Character, Byte>();\n characterToByteMap.put(FREE_SPACE_CHAR, FREE_SPACE);\n characterToByteMap.put(P1_PAWN_CHAR, P1... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns a hash code value for the object. Considers sha1 and name in the calculation. | @Override
public int hashCode() {
return super.hashCode();
} | [
"public int hashCode() {\n\t\tint code = 0;\n\t\tchar[] na = this.name.toCharArray();\n\t\tfor(char letter:na) {\n\t\t\tcode = code + Character.valueOf(letter);\n\t\t}\n\t\treturn code;\n\t}",
"public String getHash(){\r\n if (hash == null) hash = Sha1.getHash(this.toString());\r\n r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
PREFERRED Constructor for SAFSROBOTJ. | public SAFSROBOTJ(DriverInterface driver) {
this();
launchInterface(driver);
} | [
"public Trainerbot() {\n\t\tsuper ();\n\t}",
"public TerceroOT() {\n }",
"public HeteroAST() { ; }",
"public Slime() {\r\n\t}",
"public MyAgent() {\n super();\n }",
"public CommonTS() {\n }",
"public Siamese() {}",
"public OpenStegoConfig()\n {\n }",
"public AbstractRobo... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
required .cliente.TipoAcao tipoMensagem = 2 [default = LEILAO]; | public boolean hasTipoMensagem() {
return ((bitField0_ & 0x00000002) == 0x00000002);
} | [
"public void setTipo(String a) {this.tipo = a;}",
"public String getTipoCliente()\n/* 107: */ {\n/* 108:155 */ return this.tipoCliente;\n/* 109: */ }",
"public void setTipo(String tipo){\n this.tipo = tipo;\n }",
"public int getTipo(){return tipo;}",
"public int getTipo(){\n r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ / / / / / / / / / / | @Deprecated
/* */ public void setInput(Script.KernelID s, Allocation a) {
/* 65 */ throw new RuntimeException("Stub!");
/* */ } | [
"private void calculatePaths() {\n\n\n }",
"protected int snapBits(){return 9;}",
"@Override\n public int getWidth(){\n return width - 10;\n }",
"private static void EX5() {\n\t\t\r\n\t}",
"abstract protected String roam();",
"float iwdir(float pres);",
"public static void main (String ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
required bytes uuid = 6; | public boolean hasUuid() {
return ((bitField0_ & 0x00000020) == 0x00000020);
} | [
"UUID uuid();",
"public String uuid();",
"private final UUID uuid(byte[] data) {\n long msb = 0;\n long lsb = 0;\n assert data.length == 16 : \"data must be 16 bytes in length\";\n for (int i = 0; i < 8; i++)\n msb = (msb << 8) | (data[i] & 0xff);\n for (int i = 8; ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test case number: 193 /Coverage entropy=0.6931471805599453 | @Test(timeout = 4000)
public void test193() throws Throwable {
ErrorPage errorPage0 = new ErrorPage();
String[] stringArray0 = new String[8];
stringArray0[0] = "@q5II7*dzVH}z_q";
stringArray0[1] = "@q5II7*dzVH}z_q";
stringArray0[2] = "@q5II7*dzVH}z_q";
stringArray0[3] = "@q5II7*d... | [
"@Test(timeout = 4000)\n public void test191() throws Throwable {\n TextDirectoryLoader textDirectoryLoader0 = new TextDirectoryLoader();\n Instances instances0 = textDirectoryLoader0.getDataSet();\n Evaluation evaluation0 = new Evaluation(instances0);\n evaluation0.toMatrixString();\n a... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public void surfaceChanged(SurfaceHolder surfaceholder, int format, int w, int h)
{
Log.i(TAG, "Surface Changed");
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Check that the next row exists | @Override
public RowType next() {
if (!hasNext()) {
throw new NoSuchElementException();
}
return rows.next();
} | [
"public boolean next() {\n if (currentRow < rowCount - 1) {\n ++currentRow;\n return true;\n }\n return false;\n }",
"public boolean next() throws SQLException {\n/* 56 */ if (!this.open)\n/* */ {\n/* 58 */ return false;\n/* */ }\n/* 60 */ this... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the n'th key combination of the sequence. | public KeyStroke getKeyAt(int n)
{
return keys [n];
} | [
"int getNextKey();",
"int getKey3();",
"public String getNextKey() {\n\t\tnextKey = nextKey + 1;\r\n\t\tint nextId = nextKey;\r\n\t\treturn String.valueOf(nextId);\r\n\t}",
"@Override\n public int key() {\n return this.numOfKey;\n }",
"int getLastKey();",
"public int key(){\n\t\treturn 2;\n\t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Start the task. Do not use execute() or the status won't appear to have started in the task manager. | public void start() {
this.startDate = new Date();
setStatus(TaskStatus.INPROGRESS); // calls taskUpdated, so no need to call it separately
final BackgroundTaskWorker instance = this;
worker = new SwingWorker<T, Object>() {
@Override
public void done() {
... | [
"void startTask();",
"private void startTask()\n\t{\n\t\tTask task = new Task(this);\n\t\tnew Thread(task).start();\n\t}",
"public void start() {\n setStartTime(System.currentTimeMillis());\n setNumberOfPendingTasks(getTotalNumberOfTasks());\n setNumberOfRunningTasks(0);\n setSta... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
get user input and set it to result edit text > result.setText(userInput.getText()); tp1.setText(userInput.getText()); | public void onClick(DialogInterface dialog,int id) {
if (userInput.getText().toString().equals(""))
{
tp9.setText("");
p9.setImageDrawable(getResources().getDrawable(R.drawable.puntorojo));
if (completado ()) calcular.setVisibility(View.VISIBLE);
}
... | [
"public void onClick(View v) {\n float input1 = Float.parseFloat(edt1.getText().toString());\n float input2 = Float.parseFloat(edt2.getText().toString());\n double output1 = input1 * input2;\n txtv.setText(output1+ \" \");\n }",
"@Overrid... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Moves cursor to a point that doesn't obstruct combat menu | public void clearAttack() throws InterruptedException, IOException, AWTException {
JSONObject clearAttack = util.getDimsAsJSONObject("combat/clear/attack");
Point p = util.getRandomPoint(clearAttack);
move(p.getX(), p.getY());
} | [
"public void GotoXY(int x, int y)\n {\n x = x + dx;\n y = Gdx.graphics.getHeight() - y - dy;\n x -= (float) Gdx.graphics.getWidth()/2;\n y -= (float) Gdx.graphics.getHeight()/2;\n cursorPos.x = x;\n cursorPos.y = y;\n }",
"public void movePoint (\n\tint x,\n\tint y\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Auto generated getter method | public Order getCreateOrderResponse(){
return localCreateOrderResponse;
} | [
"public MethodDoc getGetter()\r\n {\r\n return m_jvdGetter;\r\n }",
"public long getGetter() {\n return getter_;\n }",
"public T get() {\n return value;\n }",
"public abstract M get();",
"@Override\n \tpublic String get() {\n \t\treturn null;\n \t}",
"public Object get... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
the names of the Json objects needed to be extracted | private String[] getWeatherDataFromJson(String forecastJsonStr, int numDays){
final String OWM_LIST = "list";
final String OWM_WEATHER = "weather";
final String OWM_TEMPERATURE = "temp";
final String OWM_MIN = "min";
final String OWM_MAX = "max";
final String OWM_DESCRIPT... | [
"@Test(timeout = 4000)\n public void test103() throws Throwable {\n String[] stringArray0 = new String[2];\n JSONObject jSONObject0 = new JSONObject(\"TcAK\\\"$\\\"d:/Zlm\", stringArray0);\n String[] stringArray1 = JSONObject.getNames(jSONObject0);\n assertNull(stringArray1);\n }",
"@Test(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
create some sample data | @RequestMapping(value = "/downloadPDF", method = RequestMethod.GET)
public ModelAndView downloadExcel() {
List<Arac> listBooks = new ArrayList<Arac>();
Kullanici kullanici = new Kullanici();
kullanici.setAdi("Ğğ İı Öö Üüu Şş Çç");
Yerler ilce = new Yerler();
ilce.setIsim("Çukurova");
listBooks.add(new ... | [
"private void createAdditionalSampleData() {\n\n\n\n }",
"public void createData() {\n\t\t\n\t\tfor (int i = 0; i < amtOfProducts; i++) {\n int randomProduct = (r.nextInt(3) + 1);\n listOfProducts.add(createRandomProduct(randomProduct));\n }\n\t}",
"public void test1()\r\n\t{\r\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ / / / / / / | public int lengthRetrievalMethod() {
/* 435 */ return length("http://www.w3.org/2000/09/xmldsig#", "RetrievalMethod");
/* */ } | [
"private void calculatePaths() {\n\n\n }",
"public static void main (String arg[]){\n\tSystem.out.println(\" ( ) ( ( \"); \n\n\tSystem.out.println(\" ( )\\\\ ) ( /( ( )\\\\ ) ( )\\\\ ) \");\n\t\n\tSystem.out.println(\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
getting the context and product list with constructor | public VehicleCategoriesAdapter(Context mCtx, ArrayList<ServicesDetail> servicesDetailArrayList) {
this.mCtx = mCtx;
this.servicesDetailArrayList = servicesDetailArrayList;
} | [
"private void initializeProductList(){\n productList = new ArrayList<>();\n Product productOne = new Product(\"laptop\", \"standard laptop with 15\\\" display\", 800.0);\n Product productTwo = new Product(\"mouse\", \"wireless mouse\", 20.0);\n Product productThree = new Product(\"keyboa... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | public static void main(String[] args) {
SolutionCompareVersion sol = new SolutionCompareVersion();
// System.out.println(sol.compareVersion("7", "7.1"));
System.out.println(sol.numberOfMoves(1, 6, 1, 1, 1));
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set the listener for the command CommonStateCountryListKnown in feature Common Listeners are static to the class, and are not to be set on every object | public static void setCommonCommonStateCountryListKnownListener (ARCommandCommonCommonStateCountryListKnownListener _ARCommandCommonCommonStateCountryListKnownListener_PARAM) {
_ARCommandCommonCommonStateCountryListKnownListener = _ARCommandCommonCommonStateCountryListKnownListener_PARAM;
} | [
"void countryListDataListener(ArrayList<String> countryList);",
"public CommonListener()\n {\n }",
"public void addAdjListener(){\n connectedCountries.addListSelectionListener(adjListController);\n }",
"private void initListener() {\n\t\tapp.getMyUserBeanManager().addOnUserStateChangeListener(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set the latitude/longitude/altitude for the satellite | public void setLla(double lat, double lon, double alt) {
latitude = lat;
longitude = lon;
altitude = alt;
locationUpdatedCalled = true;
} | [
"public void setAltitude(double altitude) {\n this.altitude = altitude;\n }",
"public void setAltitude(Float altitude) {\n this.networkObject.add(ReservedKeys.RECORD_LOCATION_ALTITUDE, altitude.toString());\n }",
"public void setAltitude(double value) {\n this.altitude = value;\n }... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return the colour of the light | public Colour colour() {
return colour;
} | [
"public Color getColor()\n { \n if(LevelVar.WITH_SIGHT && !hasBeenSeen) { return Color.BLACK; }\n return Color.YELLOW; \n }",
"public Color getColor() { return color.getColor(); }",
"public Color GetColour() {\n return(m_colour);\n }",
"public int getColor()\r\n\t{\r\n\t\treturn color;\r\n\t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns true if field success is set (has been assigned a value) and false otherwise | public boolean isSetSuccess() {
return this.success != null;
} | [
"public boolean hasSuccessValue() {\n return ((bitField0_ & 0x00000002) == 0x00000002);\n }",
"public boolean hasSuccessValue() {\n return ((bitField0_ & 0x00000002) == 0x00000002);\n }",
"public boolean isSetSuccess() {\n return __isset_bit_vector.get(__SUCCESS_ISSET_ID);\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Retrofit retrofit; com.squareup.okhttp.Response response2; | public LinkFragment() {
// Required empty public constructor
} | [
"private void getRetrofit(String url1){\n Retrofit retrofit = new Retrofit.Builder()\n .baseUrl(url1)\n .addConverterFactory(GsonConverterFactory.create()) //Here we are using the GsonConverterFactory to directly convert json data to object\n .build();\n ap... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Method that prints out every item in the users inventory in a readable format. Has a check to print a message telling the user they have no items if their inventory is empty | public void print(){
System.out.println();
if (items.size() == 0){
System.out.println("You currently have 0 items.");
System.out.println("You must add an item before you can print the items.");
try{
Thread.sleep(3000);
}
catch(InterruptedException noItemsInventory){
System.out.println("Interr... | [
"public void printInventory() {\n\tString retStr = \"\";\n\tString item = \"\";\n\tfor (int x = 0 ; x < inventory.size() ; x += 1) {\n\t if (inventory.get(x) != item) {\n\t\titem = inventory.get(x);\n\t\tretStr += item + \": \" + countItem(item) + \"\\n\";\n\t }\n\t}\n\tSystem.out.println(retStr);\n }",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
processInternetExport This method processes an internet export. | public void processInternetExport() {
String s;
// is this source directory actually a directory?
if (!sourceDirectory.isDirectory()) {
s = "";
try {
s = sourceDirectory.getCanonicalPath();
} catch (IOException ioe) {/* ignore */
... | [
"public void processExport(OutputStream output);",
"protected abstract void onExport();",
"IStatus doExport(Module module, URI uri);",
"private void exportData()\n\t{\n\t\ttry\n\t\t{\n\t\t\tserver.exportData();\n\t\t}\n\t\tcatch(IOException ioe)\n\t\t{\n\t\t\tJOptionPane.showMessageDialog(null, ERR_FILE_EXPOR... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
u = new User(); u.setId("234"); System.out.println(u); | public static void test(User u) {
User u2 = new User();
u2.setId("234");
u = u2;
System.out.println(u);
} | [
"public static void main(String[] args) {\n\n User user = User.builder().id(\"1\").name(\"builder\").age(1).build();\n\n System.out.println(user.getId());\n\n\n\n\n }",
"@Override\n public String toString() {\n return \"serverapplication.entities.User[ id=\" + getId() + \" ]\";\n }",... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Getter method for flipper. | public Flipper getFlipper() {
return flipper;
} | [
"private void flip() {\r\n if (this.flip == 0) {\r\n this.flip++;\r\n } else {\r\n this.flip--;\r\n }\r\n }",
"public short getFlip() {\n short ret = 0;\n for (int i = UR.ordinal(); i < BR.ordinal(); i++)\n ret = (short) (2 * ret + edgeOrient[... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
optional int32 cp = 3; | public Builder setCp(int value) {
cp_ = value;
onChanged();
return this;
} | [
"public interface PCS\n {\n public static final int Undefined = 0;\n public static final int UserDefined = 32767;\n }",
"static Integer m3() {\n return 99; // autoboxing 99 into an Integer.\n }",
"public int getCp() {\n return cp;\n }",
"public IntegerMemberValue(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
edit a row in the database | protected ActionListener editButton() {
return new ActionListener() {
public void actionPerformed(ActionEvent arg0) {
int selectedRow = dialog.table.getSelectedRow();
if (selectedRow == -1) {
return; // there is nothing selected
}
Object databaseObject = data.data.get(selectedRow);
... | [
"private void editDataInDatabase() {\n String where = \"_id=?\";\n ArrayList<String> colName = new ArrayList<>();\n colName.add(\"FName\");\n colName.add(\"LName\");\n ArrayList<String> columnValue = new ArrayList<>();\n columnValue.add(\"KD\");\n columnValue.add(\"P... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return all the value of the LogResources | public HashMap<String, Object> getLogResources() {
return logResources;
} | [
"public ArrayList<String> getLogs(){\r\n\t\treturn this.logs;\r\n\t}",
"@Override\n public String toString()\n {\n return\n getClass().getName() + '@' + Integer.toHexString(hashCode()) +\n \" resources=\" + (resources == null ? \"[]\" : resources.toString());\n }",
"public List<String> getCur... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Send a message to the client. | private void sendMessage(String message) {
try {
outputStream.writeObject("SERVER - " + message);
// If something happened and bytes are left over push out the extra stuff.
outputStream.flush();
showMessage("\nSERVER - " + message);
} catch (IOException e)... | [
"public void send(Message message);",
"public void sendToClient(Message message){\n\t\ttry {\n\t\t\tSystem.out.println(\"Sending message to server: \"+message._message);\n\t\t\t_outputStream.writeObject(message);\n\t\t\t_main._serverMenuController.updateChatlog();\n\t\t} catch (IOException e) {\n\t\t\te.printStac... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Redirect URI with host information. | public String redirectUriWithHost() {
return redirectUriWithHost;
} | [
"private RedirectURL(){\n\t\t\n\t}",
"String getRedirectURI();",
"public GitURI setHost (String host) {\n return create(uri.setHost(host));\n }",
"private static URI resolveUriForNR(final HttpRequestContext requestContext) {\n String host = requestContext.getRequest().getHeaderValue(\"host\")... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ access modifiers changed from: protected | public void onCreate(@Nullable Bundle bundle) {
super.onCreate(bundle);
Mainboard mainboard = Mainboard.getMainboard();
if (mainboard == null || !mainboard.isInitialized()) {
finish();
return;
}
this.mPollingId = getIntent().getStringExtra("pollingId");
... | [
"@Override\n }",
"protected void method_5557() {}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n public void publicando() {\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"pro... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Provides convenient way to set a relationship based on a ObjectKey, for example bar.setFooKey(foo.getPrimaryKey()) | public void setAttributeOptionRelatedByFromOptionIdKey(ObjectKey key) throws TorqueException
{
setFromOptionId(new Integer(((NumberKey) key).intValue()));
} | [
"public void setPrimaryKey(ObjectKey key)\n \n {\n setDorderItemId(((NumberKey) key).intValue());\n }",
"public void setPrimaryKey(ObjectKey key)\n throws TorqueException\n {\n setUserid(((NumberKey) key).intValue());\n }",
"public ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the player using the skill. | public Player getPlayer() {
return this.player;
} | [
"public static Player getPlayer(){\r\n return currentGame.getPlayer();\r\n }",
"public Player getPlayer(String username);",
"public Player getPlayer(String username){\n return playerLobby.getPlayer(username);\n }",
"public Player getPlayer() \n {\n synchronized (this)\n {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Call the TabWidget activity that does the work. | private void proceed(Account account) {
Intent i = new Intent().setClass(this,TabWidget.class);
i.putExtra("account",account);
startActivity(i);
finish();
} | [
"@Override\n\t\t\tpublic void onClick(View arg0) {\n\t\t\t\tonTabBtnClickCallBack(2);\n\t\t\t}",
"void handleTabClick(StripLayoutTab tab);",
"@Override\n public void onClick(View view) {\n Intent tabsIntent = new Intent(MainActivity.this, TabActivity.class);\n startActiv... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Asks user for a Date in format yyyyMMdd and returns it. | protected Date askForDate(String inputName)
{
printAskFor(inputName + " (YYYY-MM-DD)");
return getRequiredDate();
} | [
"public LocalDate getUsersDate() { //Pass a paramater here?\n LocalDate usersDate = myIO.readLocalDate(\"Enter a date in the format MM/dd/yyyy\");\n return usersDate;\n \n }",
"public static String dateCheck (String x){\n do{\n if(isLocalDate(x)==false){\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Getter for property "uid". | @JsonProperty
public String getUid() {
return this.uid;
} | [
"public int getUid() {\r\n return uid;\r\n }",
"public java.lang.String getUid() {\n return uid;\n }",
"public Integer getUid(){\n\t\treturn this.uid;\n\t}",
"public String getUid() {\n return super.getString(UID);\n }",
"public Long getUid() {\n\t\treturn this.uid;\n\t}",
"p... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Convenience method for getPathString(ORIGINAL). | String getOriginalPathString(); | [
"String getStringPath();",
"@Override\n\tpublic String getPathInfo() {\n\t\treturn this.original.getPathInfo();\n\t}",
"@VTID(17)\r\n java.lang.String getPath();",
"@Nullable\n\tString getNewPath();",
"private String preparePath() {\n String pathByComponent = tryAdaptTo(AemComponent.class)\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Notnull value; ensure this value is available before it is saved to the database. | public void setVideoId(String videoId) {
this.videoId = videoId;
} | [
"public String getNullValue () {\n \t return nullValue;\n }",
"@Override\n\tpublic String notNull() {\n\t\treturn null;\n\t}",
"@Override\n public String getValue() {\n return null;\n }",
"@Override\n\tpublic String mustSelectValue() {\n\t\treturn null;\n\t}... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
JFormDesigner End of variables declaration //GENEND:variables | private void CBOXItemADD(){
ASCIICBox.addItem(" Space");
ASCIICBox.addItem("NULL");
ASCIICBox.addItem("\\n Newline");
} | [
"private void initComponents() {\n\t\t// JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents\n // Generated using JFormDesigner non-commercial license\n dialogPane = new JPanel();\n contentPanel = new JPanel();\n numFlatsField = new JTextField();\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public Contact findById(Long id) {
return null;
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public void stop() {
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
A helper method for adding a attribute name/value pair into the expected values map. This is for the use of the subclasses. | protected final void prepareExpectedValues(String key, String value, boolean exactMatch) {
if (expectedValues == null) expectedValues = new HashMap<String, String>();
expectedValues.put(key, value);
comparisonType.put(key, exactMatch);
} | [
"private HashMap<String, String> addAttribute(String attr, String value) {\n\t\t// TODO Auto-generated method stub\n\t\tHashMap<String, String> hm = new HashMap<String, String>();\n\t\thm.put(Tags.feedback_attribute, attr);\n\t\thm.put(Tags.feedback_value, value);\n\t\treturn hm;\n\t}",
"private void addAttribut... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test of calcularEnergiaNecessariaDrone method, of class Calculos. | @Test
public void testCalcularEnergiaNecessariaDrone() {
System.out.println("calcularEnergiaNecessariaDrone");
double drnMassa = 0.0;
double cargaMassa = 0.0;
double velocVeiculo = 0.0;
double velocVentoLocal = 0.0;
double direcaoVento = 0.0;
double e1Lat = 0.... | [
"@Test\n public void testCalculaElasticidadeCinema() {\n double pa = 8;\n double pf = 10;\n double qa = 4;\n double qf = 3;\n double result = PrecoIdealController.calculaElasticidade(pa, pf, qa, qf);\n double expResult = -1.6666666666;\n assertEquals(expResult, re... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ 0 = up, 1 = down, 2 = left, 3 = right | public void setDirection(String dir) {
if (dir.equalsIgnoreCase("down")) {
direction[1] = true;
direction[0] = direction[2] = direction[3] = direction[4] = direction[5] = false;
}
if (dir.equalsIgnoreCase("up")) {
direction[0] = true;
direction[1] = direction[2] = direction[3] = direction[4] = ... | [
"void rightThumbDirection(double direction);",
"public BlockFace getDirection() {\n/* 103 */ switch (getData() >> 2 & 0x3)\n/* */ \n/* */ { default:\n/* 106 */ return BlockFace.UP;\n/* */ case 1:\n/* 108 */ return BlockFace.WEST;\n/* */ case 2:\n/* 110 */ ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor. | @SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
jMenu1 = new javax.swing.JMenu();
jPanel1 = new javax.swing.JPanel();
jButton1 = new javax.swing.JButton();
jButton2 = new jav... | [
"public StForm() {\n initComponents();\n }",
"public CineForm() {\n initComponents();\n }",
"public javaform() {\n initComponents();\n }",
"public EditDemographicForm() {\n initComponents();\n }",
"public FightForm() {\n initComponents();\n }",
"public For... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets a specific authToken from the database | public AuthToken getAuth(String auth) throws DataAccessException{
AuthToken token;
ResultSet rs = null;
String sql = "SELECT * FROM AuthTokens WHERE authToken = ?;";
try (PreparedStatement stmt = conn.prepareStatement(sql)){
stmt.setString(1, auth);
rs = stmt.ex... | [
"public AuthToken find(String authtoken) throws SQLException {\n\n AuthToken authToken;\n ResultSet rs = null;\n String sql = \"select * from authtokens where authtoken = ?\";\n\n try (PreparedStatement stmt = connection.prepareStatement(sql)) {\n stmt.setString(1, authtoken);... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
string MessageFileStatusId = 106; | java.lang.String getMessageFileStatusId(); | [
"java.lang.String getMessageStatus();",
"public int getMsgType(){\r\n return localMsgType;\r\n }",
"public interface MsgConstants {\n public String FAILURE_ID = \"99\";\n public String SUCCESS_ID = \"100\";\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the end date of this period, used for financial calculations such as interest accrual. The last date in the schedule period, typically treated as exclusive. If the schedule adjusts for business days, then this is the adjusted date. | public Builder endDate(LocalDate endDate) {
JodaBeanUtils.notNull(endDate, "endDate");
this.endDate = endDate;
return this;
} | [
"public void setEnd(LocalDate date)\r\n\t{\r\n\t\tthis.end = date;\r\n\t}",
"public void setEndDate(Date EndDate);",
"public void setEndDate(DateTime value) {\r\n endDate = value;\r\n }",
"public void setEndDate(Date endDate) {\n\t\tthis.endDate = currentDay;\n\t}",
"public void setDateEnd(Date dateEn... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the locator of the field. | public void setLocator(String locator)
{
this.locator = locator;
} | [
"@Override\n public void setDocumentLocator(final Locator locator) {\n this.locator = locator;\n super.setDocumentLocator(locator);\n }",
"public void setDocumentLocator (Locator locator)\n {\n }",
"protected void setFoundBy( By locator )\n\t{\n\t\tthis.foundBy = locator.toString();\n\t}... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets a link for further readings. | public String getFurtherReading() {
return furtherReading;
} | [
"public String getThispageLink();",
"private static String getURL(Reader link) throws IOException \n {\n StringBuilder strBuilder = new StringBuilder();\n int index;\n \n while ((index = link.read()) != -1) {\n strBuilder.append((char) index);\n }\n return s... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Open the EditDB window | @FXML
private void openEditDB(ActionEvent event) throws IOException {
Parent root = FXMLLoader.load(getClass().getResource("fxml/EditDB.fxml"));
Stage stage = new Stage();
stage.setScene(new Scene(root));
stage.show();
//When the EditDB window is closed, upd... | [
"private void openDataModelEditor() {\n\t\ttry {\n\t\t\tString modelname = datamodel == null || datamodel.get() == null ? DataModel.DEFAULT_NAME : datamodel.get().getName();\n\t\t\tDataModelEditor dataModelEditor = new DataModelEditor(this, false, false, null, null, null, modelname, null);\n\t\t\tdataModelEditor.se... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns an unmodifiable list containing the userdefined names that may be used to reference this schema definition. | public List<String> getNames() {
return names;
} | [
"Set<String> getUserNames();",
"public Set<QName> getDefinedAttributeNames(NodeRef nodeRef);",
"java.util.List<java.lang.String>\n getFieldNamesList();",
"List /*String*/ getAliasNames();",
"String[] getSchemaResourceNames();",
"public String[] listUserNamesAll();",
"public List<String> getConcepts... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
The region x position. | public int getRegionX() {
return (x >> 3) - 6;
} | [
"public int getXcoord() {\r\n\t\treturn xcoord;\r\n\t}",
"public int get_x_coord(){\n\t\treturn this.x_coord;\n\t}",
"public int getXPos() {\r\n return xPos;\r\n }",
"public int getXPos() { return x; }",
"public int getX() {\r\n\t\treturn coord.x;\r\n\t}",
"public int getXPosn()\n\t{\n\t\treturn... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
All interviews (screen, onsite, and so on) conducted as part of this application (includes details such as user conducting the interview, timestamp, feedback, and so on). repeated .google.cloud.talent.v4beta1.Interview interviews = 16; | public int getInterviewsCount() {
return interviews_.size();
} | [
"@Operation(summary = \"Get all interviews\")\n @ApiResponses(value = {\n @ApiResponse(responseCode = \"200\", description = \"Receive all existing interviews\")\n })\n @GetMapping(\"/interviews\")\n public ResponseEntity<List<BasicInterviewResponse>> getAllInterviews() {\n List<BasicI... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns filter components which will be added to the Log toolbar. | @NotNull
ActionGroup createActionGroup(); | [
"protected StringEntryPanel getFiltersPanel() {\n\t\tif (filtersPanel == null) {\n\t\t\tfiltersPanel = new StringEntryPanel();\n filtersPanel.setLabel(\"Excluded primers\");\n filtersPanel.setColumns(20);\n filtersPanel.setMaxLen(Integer.MAX_VALUE);\n filtersPanel.setResi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
setter to the indexer | public Indexer getIndexer() {
return indexer;
} | [
"public void setIndexed(boolean index);",
"public final void setIndex(int index) {\n/* 233 */ this.index = index;\n/* */ }",
"@Override\n\tpublic void set(int index, T e) {\n\t\t\n\t}",
"public E set(int index,E e);",
"public native void set(int index, int value) /*-{\n this[index] = value;... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
optional bool invalid = 8; | boolean getInvalid(); | [
"abstract boolean optional();",
"boolean valid() {\n\t\treturn true;\n\t}",
"boolean validate ()\n {\n\treturn false; // Stub\n }",
"public boolean isValid() {\n\treturn true;\n}",
"void setValid(boolean value);",
"@Override\n\tpublic boolean isValid()\n\t{\n\t\treturn false;\n\t}",
"boolean tryV... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
builder for searchExecutionFailure subtype | public static com.commercetools.api.models.error.SearchExecutionFailureErrorBuilder searchExecutionFailureBuilder() {
return com.commercetools.api.models.error.SearchExecutionFailureErrorBuilder.of();
} | [
"public Scan withFailureReason(String failureReason) {\n setFailureReason(failureReason);\n return this;\n }",
"public pipe.common.Common.Failure.Builder getFailureBuilder() {\n return getFailureFieldBuilder().getBuilder();\n }",
"private GetTaskRwardResult(com.google.protobuf.Gener... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Utility method created to display a popup "toast" alert | private void popupToast(String message) {
Toast.makeText(this, message, Toast.LENGTH_LONG).show();
} | [
"private void DisplayPopUP(String msg)\n {\n \tToast.makeText(getBaseContext(), msg, Toast.LENGTH_SHORT).show();\n }",
"public void showToast() {\n Context context = getApplicationContext();\n CharSequence text;\n final Toast toast;\n int duration = Toast.LENGTH_LONG;\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create an entity for this test. This is a static method, as tests for other entities might also need it, if they test an entity which requires the current entity. | public static Supplier createEntity(EntityManager em) {
Supplier supplier = new Supplier()
.companyName(DEFAULT_COMPANY_NAME)
.firstName(DEFAULT_FIRST_NAME)
.lastName(DEFAULT_LAST_NAME)
.vatNumber(DEFAULT_VAT_NUMBER)
.irsOffice(DEFAULT_IRS_OFFICE)
... | [
"protected abstract Entity createEntity();",
"EntityInstance createEntityInstance();",
"@Override\n protected void createEntity() {\n Company company = createCompany(1001);\n setEntity(company);\n }",
"public final Entity createEntity() {\n Entity entity = new Entity(this);\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
For getting server timestartTime | @GetMapping("getServerTime/{tripCabID}")
public TripCabInfo getBookingTime(@PathVariable("tripCabID") long tripCabID)
{
return this.service.getBookingTime(tripCabID);
} | [
"synchronized Date getServerStartTime()\n {\n return serverStartTime;\n }",
"int getStartTimeMs();",
"public long getStartTime ();",
"public java.lang.String getStartTime(){\r\n return localStartTime;\r\n }",
"public long getSystemStartTi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Equivalent to calling add(null, value) | @Override
public boolean add( V value ) {
return add( null, value );
} | [
"public void add(Object value) {\n\t\t// Do nothing.\n\t}",
"@Override\r\n\tpublic void add(Object value) {\r\n\t\tif(value == null) {\r\n\t\t\tthrow new NullPointerException(\"given value can not be null\");\r\n\t\t}\r\n\t\t\r\n\t\tinsert(value, size);\r\n\t}",
"@Override\n @SuppressWarnings(\"unchecked\")\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns a resource path that has the same segments as this path except for the specified segment being replaced. The index must be valid according to the number of segments in this path. | public ResourcePath replaceSegment(int index, String segment) {
String[] newSegments = getSegments();
newSegments[index] = segment;
return new ResourcePath(leadingSeparator, trailingSeparator, newSegments, 0, segmentCount, false);
} | [
"private static String escapePathSegment(String segment) throws IOException {\n try {\n URI uri = new URI(\"https\", \"temporary-service-name.temporary-domain.temporary-tld\", \"/\" + segment, \"\");\n return uri.getPath().substring(1);\n }\n catch (URISyntaxException e) {... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ This method changes the sign of a number whose value has been provided by the user | public int signo(int exp) {
if (exp % 2 == 0) {
return 1;
} else {
return -1;
}
} | [
"@Override\n\tpublic void swapSign() {\n\t\tif(enteredValue.isEmpty()) return;\n\t\tsetValue(-1*getValue());\n\t}",
"public static int sign(int checkNumber){\n if (checkNumber > 0){\n return 1;\n }else if(checkNumber == 0) {\n return 0;\n }\n else return -1;\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the interval between saves of dirty objects. | public long getPersistentObjectSaveIntervalMS() {
return PersistentObjectSaveIntervalMS;
} | [
"public long\tgetSaveInterval()\r\n\t{\r\n\t\treturn this.saveinterval;\r\n\t}",
"public long getTSDBSyncPeriod();",
"public int getKonsTextSaverPeriod(){\n\t\tint timePeriod =\n\t\t\tCoreHub.userCfg.get(Iatrix.CFG_AUTO_SAVE_PERIOD, Iatrix.CFG_AUTO_SAVE_PERIOD_DEFAULT);\n\t\tif (timePeriod == 0) {\n\t\t\t// no ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method draws the current board to the console with labels for columns. | private void displayBoard(){
//creating the numeric labels
System.out.print(" ");
for(int k=0; k<board[1].length; k++){
System.out.print((k+1)+" ");
}
//printing the current board with columns
System.out.println();
for (int i=0; i<board.length;... | [
"private void displayBoard() {\r\n\t\r\n\t\tdisplayRow(0);\r\n\t\tSystem.out.println(\"-----------\");\r\n\t\tdisplayRow(1);\r\n\t\tSystem.out.println(\"-----------\");\r\n\t\tdisplayRow(2);\r\n\t}",
"public void showBoard() {\r\n int r, c;\r\n System.out.print(\" \"); //co... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Validates if the account where you want to transfer the money is the same with the account from which the transfer is made. | public int validateNumberAccount(int optionFrom, int numberUserAccounts){
int optionTo = 0;
boolean isBadOption = false;
while (!isBadOption){
try {
LOG.info( "Type the number of account (to transfer money): " );
optionTo = IOService.getInstance().read... | [
"@Test\n public void whenTransferFromFirstAccountOnSecondAccountOfUserThenTrue() {\n Bank tempBank = new Bank();\n User firstUser = new User(\"Andrei\", \"543500\");\n tempBank.addUser(firstUser);\n Account firstAccount = new Account(10.00, \"408122\");\n Account secondAccount ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Helper routine for getOptimalPartition(...) | private Collection<Collection<Integer>> getCompatiblesFromCompFactor(
Collection<Collection<Integer>> maxCompatibles,
MaximalCompatibleFinder compatibilityEvaluator,
double compFactor) {
List<Collection<Integer>> result = new ArrayList<Collection<Integer>>();
for (Collection<Integer> mc : maxCompa... | [
"int capacity(int partitionNo);",
"private Partition[] getOptimizedPartitionsWhenTotalCombinationIsLess(int id,\n List<Integer> jobShardingDimensions, int jobPrimaryDimensionIdx, int totalCombination) {\n Partition[] partitions;\n partitions = new Partition[totalCombination];\n int index = 0;\n f... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
If the request match one url the CSFR protection will be disabled | @Override
public boolean matches(HttpServletRequest request) {
return Arrays.stream(requestMatchers).anyMatch(rm -> rm.matches(request));
} | [
"public boolean deny(Request request);",
"private void blockedURLRequested(String URL){\n\t\ttry {\n\t\t\tString message = \"Access to \" + URL + \" denied message: \\n\" + \n\t\t\t\t\t\t\t \"HTTP/1.0 403 Access Forbidden\\n\" + \n\t\t\t\t\t\t\t \"User-Agent: ProxyServer/1.0\\n\" + \"\\r\\n\";\n\t\t\tserverRes.wr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
com.chieftain.agile.service.sys [workset_idea_01] Created by Richard on 2018/6/7 | public interface ISysMenuService {
public List<SysPermission> doGetMenus(ILoginService loginService, JedisClient jedisClient, String username) throws Exception;
public List<SysPermission> findPage(String menuName,Integer pageNum,Integer pageSize);
} | [
"public java.lang.String getWork_start(){\n return localWork_start;\n }",
"WorkingSet createWorkingSet();",
"public interface RequirementWorkerService {\nList<RequirementWorker> searchByTaskInstanceId(int id);\n\n /**\n * 更新人工需求信息\n * @param rw... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
When the function of the button hasn't been made then the message appears | public void noFunction(View view) {
Toast.makeText(this, "Belum Bisa Digunakan", Toast.LENGTH_SHORT).show();
} | [
"private void noSubmit() {\n exitMessage.setText(\"Thank you for using The Horoscope!\");\n }",
"public void pressButton() throws MachineWarning{\n throw new MachineWarning(\"Button pressed with no coin inserted ..\");\n }",
"public void showButton()\n {\n \n }",
"private bool... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public boolean onTouch(View arg0, MotionEvent arg1) {
return false;
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method creates the home page with its several buttons to navigate between pages. Each button is given an action listener to bring up its associated page. In the case of the update button, a call is passed to the model to update the database with an online updated copy when connected to the network. | private JPanel createHomePage() {
final JPanel panel = new JPanel(
new GridLayout(2, 2, HOME_GAP, HOME_GAP));
// library button
final JButton libraryButton = new JButton("Library");
libraryButton.addActionListener(new ActionListener() {
public void actionPerformed(final ActionEvent e) {
myCard... | [
"public void actionPerformed(ActionEvent e) {\r\n\t\t\t\t\r\n\t\t\t\tHomePage home1 = new HomePage();\r\n\t\t\t\thome1.Show();\r\n\t\t\t\tdispose();\r\n\t\t\t\t\r\n\t\t\t}",
"public void homeButtonPushed(ActionEvent event) throws IOException{\n goHomePage(event);\n }",
"private void btnHomePageActionP... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
DELETE /coursematerialaccesses/:id : delete the "id" courseMaterialAccess. | @DeleteMapping("/course-material-accesses/{id}")
@Timed
public ResponseEntity<Void> deleteCourseMaterialAccess(@PathVariable Long id) {
LOGGER.debug("REST request to delete CourseMaterialAccess : {}", id);
courseMaterialAccessRepository.delete(id);
return ResponseEntity.ok().headers(HeaderUtil.createEntityDelet... | [
"public String deleteByCourseId(int courseId) throws RecordNotFoundException;",
"public void delete(Long permissionId);",
"void deleteRoleAccessLinkByRoleId(long roleId);",
"@Override\r\n\tpublic void delete(int Id) {\n\t\tsession.getCurrentSession().delete(getTypeMaterial(Id));\r\n\t}",
"public void delete... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
see DbFile.java for javadocs | public ArrayList<Page> insertTuple(TransactionId tid, Tuple t)
throws DbException, IOException, TransactionAbortedException {
// some code goes here
return null;
// not necessary for lab1
} | [
"public File getDbFile(){\n return theDbFile;\n }",
"private void initDBaseFile()\n throws IOException {\n // position the record pointer at 0\n rafDbf.seek( 0 );\n\n /*\n // read the file type\n file_type = fixByte( rafDbf.readByte() );\n\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |