query stringlengths 7 33.1k | document stringlengths 7 335k | metadata dict | negatives listlengths 3 101 | negative_scores listlengths 3 101 | document_score stringlengths 3 10 | document_rank stringclasses 102
values |
|---|---|---|---|---|---|---|
TODO Autogenerated method stub | @Override
protected void onSaveInstanceState(Bundle outState) {
super.onSaveInstanceState(outState);
if (outState != null) {
outState.putParcelableArrayList(NewsBean.KEY_NEWS, news);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.66708666",
"0.65675074",
"0.65229905",
"0.6481001",
"0.64770633",
"0.64584893",
"0.6413091",
"0.63764185",
"0.6275735",
"0.62541914",
"0.6236919",
"0.6223816",
"0.62017626",
"0.61944294",
"0.61944294",
"0.61920846",
"0.61867654",
"0.6173323",
"0.61328775",
"0.61276996",
"0... | 0.0 | -1 |
TODO all this logic to find/search boundary has to move to separate class say BoundaryRepository and just call the api/method here | public Boolean isBoundaryExists(Property property,RequestInfo requestInfo,Long id){
StringBuffer BoundaryURI = new StringBuffer();
BoundaryURI.append(env.getProperty("egov.services.egov_location.hostname"))
.append(env.getProperty("egov.services.egov_location.searchpath"));
URI uri = UriComponentsBuilder.fromUriString(BoundaryURI.toString())
.queryParam("Boundary.tenantId", property.getTenantId()).queryParam("Boundary.id", id).build(true)
.encode().toUri();
logger.info("BoundaryRepository BoundaryURI ---->> "+BoundaryURI.toString()+" \n request uri ---->> "+uri);
try {
BoundaryResponseInfo boundaryResponseInfo = restTemplate.getForObject(uri, BoundaryResponseInfo.class);
logger.info("BoundaryRepository BoundaryResponseInfo ---->> "+boundaryResponseInfo);
if (boundaryResponseInfo.getResponseInfo() != null && boundaryResponseInfo.getBoundary().size() != 0) {
return true;
} else {
throw new InvalidPropertyBoundaryException(env.getProperty("invalid.property.boundary"),
env.getProperty("invalid.property.boundary.message").replace("{boundaryId}", "" + id),
requestInfo);
}
} catch (HttpClientErrorException ex) {
throw new ValidationUrlNotFoundException(env.getProperty("invalid.property.boundary.validation.url"),
uri.toString(), requestInfo);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Map<Integer, Geometry> getBoundary() throws SQLException {\n return retrieveExpected(createNativeBoundaryStatement(), GEOMETRY);\n }",
"Collection<? extends Boundary> getIsBoundaryNodeOf();",
"public int getBoundary() {\n return boundary;\n }",
"public void computeStoredBou... | [
"0.5780093",
"0.5687098",
"0.56201917",
"0.5517563",
"0.55118656",
"0.5472107",
"0.54051304",
"0.53573126",
"0.5350498",
"0.53294873",
"0.5312649",
"0.53028417",
"0.5298494",
"0.5295584",
"0.52856123",
"0.52598906",
"0.5240829",
"0.52121484",
"0.51923835",
"0.5158059",
"0.515... | 0.5811683 | 0 |
TODO Autogenerated method stub | public static void main(String[] args) throws IOException {
String path = System.getProperty("user.dir") + "\\src\\excelFileHandling\\TestData1.xls";
FileInputStream file = new FileInputStream(path);
HSSFWorkbook wb = new HSSFWorkbook(file);
HSSFSheet sheet = wb.createSheet("Sheet2");
String[][] data= {{"Name","Surname","Address"},
{"Vishal","Shinde","Pune"},
{"Satya","Shinde","Pune"}
};
for (int i=0; i<data.length; i++)
{
HSSFRow row =sheet.getRow(i);
if(row==null)
row= sheet.createRow(i);
for (int j=0; j<data[0].length; j++)
{
HSSFCell cell = row.getCell(j);
if(cell == null)
cell = row.createCell(j);
cell.setCellValue(data[i][j]);
}
}
FileOutputStream fileout = new FileOutputStream(path);
wb.write(fileout);
fileout.close();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.608016... | 0.0 | -1 |
Start method which sets the scene. | public void start(Stage primaryStage, MainMenuGUI mainMenuGUI, Socket socket) {
stage = primaryStage;
this.mainMenuGUI = mainMenuGUI;
this.socket = socket;
BorderPane borderPane = new BorderPane();
ToolBar toolBar = new ToolBar();
Button backButton = new Button("Back");
backButton.setOnAction(event -> mainMenuGUI.start());
toolBar.getItems().add(backButton);
Separator separator = new Separator();
separator.setOrientation(Orientation.VERTICAL);
VBox vBox = new VBox();
vBox.setAlignment(Pos.CENTER);
HBox hBox = new HBox();
hBox.setPadding(new Insets(0, 0, 0, 13));
hBox.prefWidthProperty().bind(toolBar.widthProperty().subtract(60));
Label roomCodeLabel = new Label("Game code: ");
roomCodeLabel.setAlignment(Pos.CENTER);
roomCodeLabel.setFont(Font.font("Arial", FontWeight.LIGHT, 20));
TextField textField = new TextField();
textField.setPrefWidth(92);
Button buttonJoinGame = new Button("Join game");
buttonJoinGame.setAlignment(Pos.CENTER);
buttonJoinGame.setOnAction(event -> joinGameRoom(textField.getText()));
Separator separator2 = new Separator();
separator2.setOrientation(Orientation.VERTICAL);
Button buttonRefreshGames = new Button("Refresh games ");
buttonRefreshGames.setOnAction(event -> setAvailableGames());
hBox.getChildren().addAll(separator, roomCodeLabel, textField, buttonJoinGame, separator2, buttonRefreshGames);
hBox.setSpacing(8);
borderPane.setTop(toolBar);
Label joinPublicGame = new Label("Public games");
joinPublicGame.setTextAlignment(TextAlignment.CENTER);
joinPublicGame.setFont(Font.font("Arial", FontWeight.BOLD, 30));
listView = new ListView<>();
setAvailableGames();
toolBar.getItems().add(hBox);
vBox.getChildren().addAll(joinPublicGame, listView);
vBox.setPadding(new Insets(10));
borderPane.setCenter(vBox);
Scene scene = new Scene(borderPane, 500, 490);
stage.setTitle("Join game");
stage.setScene(scene);
stage.show();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void startScene()\r\n\t{\r\n\t\tthis.start();\r\n\t}",
"public void setupScene() {\n\t\tplayScene = new Scene(new Group());\n\t\tupdateScene(playScene);\n\t\twindow.setScene(playScene);\n\t\twindow.show();\n\t}",
"public void Scene() {\n Scene scene = new Scene(this.root);\n this.stage.set... | [
"0.8434001",
"0.75694966",
"0.7500863",
"0.7021536",
"0.69439274",
"0.6922905",
"0.6899865",
"0.68977827",
"0.6872944",
"0.68511623",
"0.6807696",
"0.678296",
"0.676285",
"0.67599225",
"0.6747026",
"0.66947585",
"0.66910726",
"0.66788214",
"0.6666594",
"0.66658676",
"0.666352... | 0.0 | -1 |
Sets the list of available public games. | private void setAvailableGames() {
try {
listView.getItems().clear();
DataOutputStream dataOutputStream = new DataOutputStream(socket.getOutputStream());
dataOutputStream.writeUTF("GLst");
ObjectInputStream objectInputStream = new ObjectInputStream(socket.getInputStream());
HashMap<String, String> list = (HashMap<String, String>) objectInputStream.readObject();
for (String roomCode : list.keySet()) {
HBox hboxList = new HBox();
hboxList.setSpacing(8);
Button buttonJoin = new Button("Join");
buttonJoin.setOnAction(event -> joinGameRoom(roomCode));
Separator separator = new Separator();
separator.setOrientation(Orientation.VERTICAL);
Label roomName = new Label(list.get(roomCode));
roomName.setFont(Font.font("Arial", 20));
hboxList.getChildren().add(buttonJoin);
hboxList.getChildren().add(separator);
hboxList.getChildren().add(roomName);
listView.getItems().add(hboxList);
}
} catch (IOException | ClassNotFoundException e) {
e.printStackTrace();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void setAvailableGames(Set<Integer> gameIds);",
"public void setGames() {\n\n games = new HashMap<String, Game>();\n\n for(Game g : jsonManager.getGamesFromJson())\n games.put(g.getTitle(), g);\n\n }",
"public static void updateGamesList(Set<Game> games) {\n\t\tgameSet = games;\n\t}... | [
"0.72747415",
"0.6687553",
"0.63213134",
"0.62442034",
"0.6150924",
"0.5688479",
"0.5672762",
"0.5654856",
"0.5643196",
"0.5615947",
"0.56036955",
"0.5601746",
"0.5589857",
"0.5584852",
"0.5568003",
"0.55241424",
"0.5518919",
"0.5515153",
"0.5507975",
"0.5464673",
"0.541239",... | 0.58622515 | 5 |
Used to join a game room on the basis of the room code. For public games their is no need to type a room code since the 'join' button is already bound to the button. | public void joinGameRoom(String roomCode) {
try {
roomCode = roomCode.toLowerCase();
DataOutputStream out = new DataOutputStream(socket.getOutputStream());
DataInputStream in = new DataInputStream(socket.getInputStream());
out.writeUTF("Conn" + roomCode);
String response = in.readUTF();
switch (response.substring(0, 4)) {
case "Conf":
String start = "YELLOW";
String you = "YELLOW";
if (response.charAt(4) == 'R')
start = "RED";
if (response.charAt(5) == 'R')
you = "RED";
ObjectInputStream inObj = new ObjectInputStream(socket.getInputStream());
ArrayList<String> gameChat = new ArrayList<>((ArrayList<String>) inObj.readObject());
inObj = new ObjectInputStream(socket.getInputStream());
ArrayList<String> mainChat = new ArrayList<>((ArrayList<String>) inObj.readObject());
new GameGUI().start(stage, mainMenuGUI, socket, roomCode, gameChat, mainChat, start, you);
break;
case "Full":
AlertHandler.show(Alert.AlertType.ERROR, "Room Full", "Room Full", "The room you tried to join is full.");
break;
case "Invl":
AlertHandler.show(Alert.AlertType.ERROR, "Invalid Code", "Invalid Code", "The selected room does not exist");
break;
}
} catch (IOException | ClassNotFoundException e) {
e.printStackTrace();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void joinRoom(int roomId) throws RoomNotFoundException, RoomPermissionException, IOException;",
"@Override\n\tpublic SocketIOSocket join(String room) {\n\t\tString roomName = namespace.getName() + \"/\" + room;\n\t\tthis.manager.onJoin(this.id, roomName);\n//\t\tthis.manager.store.publish('join', this.id, name);... | [
"0.70898896",
"0.671927",
"0.66155845",
"0.65513015",
"0.6470525",
"0.6461551",
"0.6369708",
"0.63306224",
"0.63238776",
"0.6280479",
"0.62641734",
"0.61725247",
"0.6158455",
"0.6102057",
"0.60851544",
"0.605515",
"0.603837",
"0.6005022",
"0.59531534",
"0.59206235",
"0.591432... | 0.7181064 | 0 |
Constructs an action to send the input message immediately. | public MessageResponseAction(Message message) {
this(message, 0);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"SendAction createSendAction();",
"Action createAction();",
"Action createAction();",
"Action createAction();",
"public void actionPerformed(ActionEvent e) {\n\n if (inputField.getText().trim().length() == 0) {\n return;\n }\n try {\n\n String input = inputField.ge... | [
"0.6511965",
"0.6304241",
"0.6304241",
"0.6304241",
"0.6085278",
"0.5954076",
"0.5878162",
"0.5816696",
"0.5795234",
"0.57850844",
"0.57431066",
"0.5691893",
"0.5672664",
"0.56567395",
"0.56485075",
"0.56164885",
"0.56139785",
"0.55959004",
"0.55782104",
"0.557401",
"0.556636... | 0.52263224 | 50 |
Constructs an action to send the input message at some time in the future. | public MessageResponseAction(Message message, long delayInMs) {
this.message = message;
this.delayInMs = delayInMs;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"SendAction createSendAction();",
"Action createAction();",
"Action createAction();",
"Action createAction();",
"protected void takeAction() {\n lastAction = System.currentTimeMillis();\n }",
"ActionEvent createActionEvent();",
"public void createAction() {\n }",
"public ScheduledActionAction()... | [
"0.6135316",
"0.6039478",
"0.6039478",
"0.6039478",
"0.58711684",
"0.564407",
"0.55133927",
"0.55125755",
"0.5507013",
"0.54972506",
"0.5490514",
"0.54902583",
"0.5477362",
"0.5444155",
"0.5430481",
"0.5404792",
"0.54011077",
"0.53999716",
"0.53782696",
"0.5360334",
"0.531937... | 0.48505047 | 82 |
variables values listeners Inverse Binding Event Handlers | public ActivityMeetingRoomBindingImpl(@Nullable androidx.databinding.DataBindingComponent bindingComponent, @NonNull View root) {
this(bindingComponent, root, mapBindings(bindingComponent, root, 15, sIncludes, sViewsWithIds));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void onVariableChanged(Object... newValue);",
"private void addBindingAndListener() {\n // When the simulation has more than one time of simulation this property change the selected element\n // of time series.\n this.changeListener = (observable, oldValue, newValue) -> {\n if (ne... | [
"0.6254753",
"0.6237819",
"0.61801654",
"0.6102441",
"0.6097688",
"0.6097688",
"0.60286963",
"0.6000724",
"0.5999918",
"0.597477",
"0.5944254",
"0.5941",
"0.5910319",
"0.5901218",
"0.58392465",
"0.5808331",
"0.5771617",
"0.57671994",
"0.5763968",
"0.57020324",
"0.5686201",
... | 0.0 | -1 |
TODO: this is not spec | @Test
public void testAuthenticatedCall() throws Exception {
final Callable<Void> callable = () -> {
try {
final Principal principal = whoAmIBean.getCallerPrincipal();
Assert.assertNotNull("EJB 3.1 FR 17.6.5 The container must never return a null from the getCallerPrincipal method.", principal);
Assert.assertEquals("user1", principal.getName());
} catch (RuntimeException e) {
e.printStackTrace();
Assert.fail((("EJB 3.1 FR 17.6.5 The EJB container must provide the caller?s security context information during the execution of a business method (" + (e.getMessage())) + ")"));
}
return null;
};
Util.switchIdentitySCF("user1", "password1", callable);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public int describeContents() { return 0; }",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void test() {\n\t\t\t}",
"@Override public int describeContents() { return 0; }",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\n public v... | [
"0.56523424",
"0.5597048",
"0.5587474",
"0.5497658",
"0.5457998",
"0.5455501",
"0.5376528",
"0.53371453",
"0.53205144",
"0.52979654",
"0.5252555",
"0.5231196",
"0.5198868",
"0.51735383",
"0.51650214",
"0.51591635",
"0.5145093",
"0.514268",
"0.5113025",
"0.5113025",
"0.5113025... | 0.0 | -1 |
find by product unit type length | ProductUnitTypeLength findByUnitTypeAbbr(String productUnitType); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Length getUnit() {\n return unit;\n }",
"public double getLength();",
"public void setUnit(Length units) {\n unit = units;\n }",
"public abstract void getLength(double length);",
"abstract double getLength();",
"float getLength();",
"float getLength();",
"public long ge... | [
"0.60962635",
"0.56981665",
"0.5693106",
"0.56791246",
"0.5678794",
"0.56698394",
"0.56698394",
"0.5618626",
"0.5612405",
"0.560575",
"0.5553043",
"0.55166703",
"0.54699194",
"0.54507",
"0.54336345",
"0.54058784",
"0.5382336",
"0.5365903",
"0.536467",
"0.53564805",
"0.5356480... | 0.67123747 | 0 |
Stage an application directory with default resource limits | void stageApplicationWithDefaultResourceLimits(File stagingDir); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void stageApplicationWithRemoteResourceLimits(File stagingDir);",
"public Arguments create() throws IOException {\r\n Arguments args = new Arguments();\r\n ArrayList vmArgs = new ArrayList();\r\n \r\n // Start empty framework\r\n if (clean) {\r\n // Remove bundle directories\r\n File[] c... | [
"0.74800426",
"0.5080485",
"0.50116503",
"0.49334714",
"0.4902673",
"0.49009624",
"0.4868476",
"0.4862545",
"0.4835054",
"0.47924",
"0.4776944",
"0.47625503",
"0.47554055",
"0.46824443",
"0.46518728",
"0.46071848",
"0.45732874",
"0.4552523",
"0.45508504",
"0.45089534",
"0.450... | 0.7885146 | 0 |
Stage an application directory with remote resource limits | void stageApplicationWithRemoteResourceLimits(File stagingDir); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void stageApplicationWithDefaultResourceLimits(File stagingDir);",
"public void executelaunchDirectoryFiler() {\n \t\tif (conf.getProperty(\"rootDirectory\") == null)\n \t\t\tUtil.fatalError(\"You must provide a root directory for the filer with -r or --rootDirectory\");\n \t\tif (conf.getProperty(\"secret\") ==... | [
"0.72252685",
"0.5409431",
"0.51491964",
"0.4848858",
"0.47444463",
"0.47336105",
"0.4694408",
"0.4658931",
"0.4624494",
"0.4601741",
"0.4563013",
"0.45410872",
"0.45007467",
"0.44875714",
"0.4483243",
"0.44618544",
"0.4459382",
"0.44590276",
"0.4453038",
"0.44494468",
"0.444... | 0.816464 | 0 |
Set the SDK version. This is currently used for logging purposes. | void setSdkVersion(String sdkVersion) {
this.sdkVersion = Preconditions.checkNotNull(sdkVersion);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void setVersion(long version);",
"void setVersion(String version);",
"void setVersion(String version);",
"public void setVersion(String version);",
"private void setVersionNumber(int version) {\n versionNumber = version;\n }",
"public void setVersion(int version) {\n this.version = versi... | [
"0.7361073",
"0.7334377",
"0.7334377",
"0.7179841",
"0.7151602",
"0.7054071",
"0.7054071",
"0.70501596",
"0.7027178",
"0.698401",
"0.6922424",
"0.6922424",
"0.6918074",
"0.68909407",
"0.6854795",
"0.6852665",
"0.68515915",
"0.6848424",
"0.6837265",
"0.6827964",
"0.6826553",
... | 0.7199915 | 3 |
Returns the SDK version if it has been set and a string indicating an unknown version if it has not been set. | String getSdkVersion() {
return sdkVersion;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static String getSDKVersion() {\n return Constants.Z_SDK_ID;\n }",
"@Override\n\tpublic String getSDKVersion() {\n\t\treturn null;\n\t}",
"default String getVersion()\n {\n return getString( \"version\", \"Unknown Version\");\n }",
"public String getSdkVersion() {\n ... | [
"0.73901147",
"0.73209",
"0.7156594",
"0.70125675",
"0.6916612",
"0.6879842",
"0.6854817",
"0.6665663",
"0.6665663",
"0.665031",
"0.6634799",
"0.66046464",
"0.6599919",
"0.6599919",
"0.65787023",
"0.6577729",
"0.65707207",
"0.65707207",
"0.6567143",
"0.6567143",
"0.6567143",
... | 0.6986566 | 4 |
long sid = allList.get(position).getId(); | @Override
public void onClick(View v) {
long sid = allListOkLast.get(position).getId();
Query<GpsPointDetailData> build = db.getGpsPointDetailDao().queryBuilder().where(GpsPointDetailDao.Properties.Id.eq(sid)).build();
db.deleteGpsPointDetailData(sid);
adapter.removeItem(position);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"int getListSnId(int index);",
"@Override\n public long getItemId(int position) {\n return listInfoList.get(position).id;\n }",
"public int getListId()\n {\n return listId;\n }",
"public int getListSnId(int index) {\n return listSnId_.getInt(index);\n }",
"publi... | [
"0.7415909",
"0.68516904",
"0.6770338",
"0.6698373",
"0.66612315",
"0.65538806",
"0.65448725",
"0.64333916",
"0.64316744",
"0.6387246",
"0.6356007",
"0.63291055",
"0.625597",
"0.6196905",
"0.6187403",
"0.61346835",
"0.6132375",
"0.6130261",
"0.6116812",
"0.6116812",
"0.609512... | 0.0 | -1 |
TODO Autogenerated method stub | @Override
public void onReceive(Context context, Intent intent) {
String action = intent.getAction();
if (MainService.ACTION_SYNFINSH_SPORTS.equals(action)) { // 同步 运动模式数据
initdata();
dismissLoadingDialog();
Toast.makeText(getApplicationContext(), getString(R.string.data_refresh_success), Toast.LENGTH_LONG).show(); // 数据刷新成功
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.66708666",
"0.65675074",
"0.65229905",
"0.6481001",
"0.64770633",
"0.64584893",
"0.6413091",
"0.63764185",
"0.6275735",
"0.62541914",
"0.6236919",
"0.6223816",
"0.62017626",
"0.61944294",
"0.61944294",
"0.61920846",
"0.61867654",
"0.6173323",
"0.61328775",
"0.61276996",
"0... | 0.0 | -1 |
get scan package path | private void init() {
Mvcs.scanPackagePath = analyseScanPath();
if(StringHandler.isEmpty(Mvcs.scanPackagePath))
throw new RuntimeException("No scan path has been set! you need to setup ScanPackage annotation");
//put all class into the list
List<String> allClassNames = scanAllClassNames();
if(StringHandler.isEmpty(allClassNames)) //some loader may have no return value
return ;
for(String pkgPath : allClassNames){
list.add(ClassUtil.getClass(pkgPath));
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private String analyseScanPath() {\n\t\t//1. get main module from init params\n\t\tString mainModule = Mvcs.servletConfig.getInitParameter(\"mainModule\");\n\t\tClass<?> cl = ClassUtil.getClass(mainModule);\n\t\tif(cl.isAnnotationPresent(ScanPackage.class)){\n\t\t\tScanPackage ann = cl.getAnnotation(ScanPackage.cl... | [
"0.7563837",
"0.6140582",
"0.6066505",
"0.6057425",
"0.6023511",
"0.59481996",
"0.59112686",
"0.58329487",
"0.5814381",
"0.57609934",
"0.5737745",
"0.5721623",
"0.5705816",
"0.56899655",
"0.5666068",
"0.56654507",
"0.56471807",
"0.5642545",
"0.5634594",
"0.5615133",
"0.560828... | 0.0 | -1 |
get scan path from ScanPackage annotation | private String analyseScanPath() {
//1. get main module from init params
String mainModule = Mvcs.servletConfig.getInitParameter("mainModule");
Class<?> cl = ClassUtil.getClass(mainModule);
if(cl.isAnnotationPresent(ScanPackage.class)){
ScanPackage ann = cl.getAnnotation(ScanPackage.class);
//get annotation path value
return ann.path();
}
//default return null
return null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public ArrayList<String> getScanPath() {\n return scanPath;\n }",
"String getAnnotationFile() {\n File imgFile = photos[fileIndex];\n String parentDir = imgFile.getParent();\n String fileName = imgFile.getName();\n String annotationName = fileName.replace(fileName.substring(... | [
"0.5908536",
"0.5488229",
"0.54819024",
"0.5455609",
"0.5383588",
"0.538064",
"0.5278927",
"0.52434003",
"0.5201921",
"0.5180166",
"0.517584",
"0.5148378",
"0.5141511",
"0.5121575",
"0.50933534",
"0.5075306",
"0.5075306",
"0.5053011",
"0.50388736",
"0.49889654",
"0.49585524",... | 0.82935876 | 0 |
get all class name | public abstract List<String> scanAllClassNames(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public final String toStringClassName() {\r\n \t\tString str = this.getClass().getName();\r\n \t\tint lastIx = str.lastIndexOf('.');\r\n \t\treturn str.substring(lastIx+1);\r\n \t}",
"private String getClassname() {\r\n\t\tString classname = this.getClass().getName();\r\n\t\tint index = classname.lastIndexOf('.'... | [
"0.7561515",
"0.752236",
"0.7515027",
"0.74836016",
"0.74836016",
"0.74836016",
"0.74746877",
"0.7386459",
"0.7172089",
"0.71484315",
"0.709793",
"0.709793",
"0.709095",
"0.70711184",
"0.7061199",
"0.705052",
"0.70218533",
"0.7014894",
"0.7014841",
"0.7010813",
"0.6968763",
... | 0.6889471 | 22 |
set the ioc container | public void analyseAnnotations(AbsIoc ioc){
//0. makeup a cache first
Map<String, IocObject> cacheMap = new HashMap<String, IocObject>();
IocObject iocObj = null;
for(Class<?> cl : list){
iocObj = new IocObject();
iocObj.setType(cl);
//1.tell if there is an IocBean
if(!cl.isAnnotationPresent(IocBean.class))
continue ;
//2.if have the class name
IocBean bean = cl.getAnnotation(IocBean.class);
if(StringHandler.isEmpty(bean))
continue ;
String className = bean.name();
if(StringHandler.isEmpty(className))
className = cl.getSimpleName(); //if no name has been set, then use simple name
//3. scope properties, here only use default properties
if(cl.isAnnotationPresent(IocScope.class)){
IocScope scope = cl.getAnnotation(IocScope.class);
String val = scope.value();
//default is singleton
if(StringHandler.isEmpty(val))
val = "singleton";
iocObj.scope = val.trim();
}
//4. initial a instance
try {
if(iocObj.scope.equals("singleton"))
iocObj.instanceObj = cl.newInstance();
} catch (InstantiationException e) {
e.printStackTrace();
} catch (IllegalAccessException e) {
e.printStackTrace();
}
//XXX later change to logger
System.out.println("success load class: " + cl.getName());
cacheMap.put(className, iocObj);
}
//finally replace the map
ioc.iocMap = cacheMap;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setContainer(RuntimeContainer container)\n {\n this.container = container;\n }",
"public void setContainer(String container) {\n this.container = container;\n }",
"ComponentContainer container(ContextDefinition context);",
"void setObjectFactory(Injectable injectable, Objec... | [
"0.65594333",
"0.57340956",
"0.56779325",
"0.5667857",
"0.56179756",
"0.5601341",
"0.5585383",
"0.55160064",
"0.5496556",
"0.5463542",
"0.54608244",
"0.545623",
"0.5414547",
"0.5357245",
"0.53568333",
"0.53459495",
"0.53160304",
"0.5315574",
"0.5289466",
"0.52703595",
"0.5267... | 0.0 | -1 |
IocLoader ld = new AnnotationIocLoader(); | public static void main(String[] args) {
System.out.println(System.getProperty("user.dir"));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public interface AnnotationReader\r\n{\r\n /**\r\n * Accessor for the annotations packages supported by this reader.\r\n * @return The annotations packages that will be processed.\r\n */\r\n String[] getSupportedAnnotationPackages();\r\n\r\n /**\r\n * Method to get the MetaData for a class... | [
"0.6817076",
"0.6445009",
"0.6360364",
"0.63037217",
"0.6295115",
"0.62257487",
"0.6051403",
"0.6051308",
"0.59356034",
"0.5912036",
"0.588732",
"0.58491564",
"0.58491564",
"0.58170485",
"0.5812134",
"0.579225",
"0.57441264",
"0.57375324",
"0.5734815",
"0.5722091",
"0.5713912... | 0.0 | -1 |
Marks the tiles the enemy snake can reach as filled unless our head is inside one of those tiles | public void markDangerTiles() {
List<Tile> dangerTiles = this.gb.nearByTiles(this.enemy_head_x, this.enemy_head_y);
if (dangerTiles.contains(this.gb.get(this.us_head_x, this.us_head_y)))
return; // Don't force fill if our head is there
for (Tile t : dangerTiles)
t.setForceFilled(true);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void markEmptyFields(int shipSize){\n\t\tint x = hitLocation3.x;\n\t\tint y = hitLocation3.y;\n\t\t\n\t\tif( hitLocation2==null && hitLocation3 !=null ){\n\t\t\tif(x-1 >= 0 && y - 1 >= 0){\n\t\t\t\topponentShootTable[x-1][y-1] = true;\n\t\t\t\tpossibleshoots.remove( new TabLocation(x-1, y-1) );\t//po skosie... | [
"0.65183455",
"0.64601797",
"0.64212644",
"0.6270122",
"0.6160191",
"0.61099195",
"0.6097728",
"0.60694677",
"0.60652214",
"0.60302794",
"0.60084355",
"0.59775424",
"0.5974332",
"0.5947602",
"0.58726615",
"0.58674407",
"0.5860672",
"0.58600664",
"0.584838",
"0.58389825",
"0.5... | 0.75997186 | 0 |
Function called every turn | @Override
public DirType getMove(GameState state) {
if (print) System.out.println("\n\n");
this.gb.update(state); // Must be done every turn
this.findEnemySnake(); // Update Enemy Snake's head Location
this.markDangerTiles(); // Mark tiles the Enemy Snake can reach and filled
if (print) this.gb.printBoard();
if (print) System.out.println("DIVEBOMB ENTER -> Us_X: " + this.us_head_x + ", Us_Y: " + this.us_head_y + " -> " + this.us_num);
Tile target = this.diveBomb();
if (print) System.out.print("DIVEBOMB EXIT -> Target_X: " + target.getX() + " Target_Y: " + target.getY());
DirType retVal = getDir(target);
if (print) System.out.println(" Dir: " + retVal);
if (this.us_num == 0) {
System.out.println("\n\n\n");
GameBoard gb= new GameBoard(state, 1,0);
gb.update(state);
float val = USuckUnless.grade(state, this.us_num, DirType.South);
System.out.println(val);
this.gb.printBoard();
}
return retVal;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected void runEachSecond() {\n \n }",
"@Override\n public void run() {\n systemTurn();\n }",
"@Override\n public void run() {\n systemTurn();\n }",
"... | [
"0.6657651",
"0.66370636",
"0.66370636",
"0.66370636",
"0.66370636",
"0.66370636",
"0.66370636",
"0.66370636",
"0.66370636",
"0.66370636",
"0.65833306",
"0.6520113",
"0.6520009",
"0.64971167",
"0.64675444",
"0.6447917",
"0.64343184",
"0.64314824",
"0.642743",
"0.6414",
"0.635... | 0.0 | -1 |
Using a tile it chooses the Dir to reach that tile, updates this.Head vars | public DirType getDir(Tile target) {
// If the target is the same as our current location, that means no targets were reachable
// We get all open tiles next to our head
if (target.getX() == this.us_head_x && target.getY() == this.us_head_y) {
if (print) System.out.println(" PANIC!!");
List<Tile> options = this.gb.panicOpenTiles(target);
// There are no open tiles next to our head
if (options.size() == 0) { // Accept Death
if (print) System.out.println(" WE DIE!");
return DirType.South;
// There are open tiles, so we find the one that results in the longest path
} else {
int longestPath = -1;
Tile newTarget = target;
// For every tile next to our head, find the longest path to a tile near us.
// TODO maybe find a better target to aim for during this panic state?
for (Tile t : options) {
this.dk.setPanicMode();
LinkedList<Tile> path = this.dk.path(target, t, gb);
this.dk.undoPanicMode();
// If a path exists, see if its longer than what we had before
// TODO the idea of going for longest might mean it's easier to circle around us and kill us
if (path == null) continue;
int pathLength = path.size();
if (this.print) System.out.println(pathLength);
if (pathLength > longestPath) {
newTarget = t;
longestPath = pathLength;
}
}
if (this.print) System.out.println();
target = newTarget;
}
}
// just use our head and target location to figure out which direction to move
int dist_x = this.us_head_x - target.getX();
int dist_y = this.us_head_y - target.getY();
assert(dist_x != 0 && dist_y != 0);
if (abs(dist_x) > abs(dist_y)) {
if (dist_x > 0) {
this.us_head_x -= 1;
return DirType.West;
} else {
this.us_head_x += 1;
return DirType.East;
}
} else if(dist_y > 0) {
this.us_head_y -= 1;
return DirType.North;
} else {
this.us_head_y += 1;
return DirType.South;
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void setTile(Tile tile) {\n _tile = tile;\n }",
"private void setMainTankDir() {\n Dir dir = myTank.getDir();\n\n if(!bL&&!bU&&!bR&&!bD){\n myTank.setMoving(false);\n Client.INSTANCE.send(new TankStopMsg(getMyTank()));\n }else {\n ... | [
"0.58402",
"0.5753984",
"0.5618813",
"0.5573186",
"0.5369425",
"0.53252953",
"0.5317182",
"0.52478194",
"0.5207775",
"0.511067",
"0.5097684",
"0.5071323",
"0.50652266",
"0.505349",
"0.5033898",
"0.5019683",
"0.50029427",
"0.500002",
"0.49906674",
"0.49679226",
"0.4935227",
... | 0.5327411 | 5 |
The goal of this is to cut off our opponent and make them run into us and that's it no food Returns Our Snake Head's Current Location When No Targets Are Reachable. | public Tile diveBomb() {
List<Tile> targets = this.findTargets();
Tile us_tile = this.gb.get(this.us_head_x, this.us_head_y);
LinkedList<Tile> shortestPath = null;
// Chose the shortest path
//System.out.println("HeadX: " + this.us_head_x + " HeadY: " + this.us_head_y);
//System.out.println("EnemyX: " + this.enemy_head_x + " EnemyY: " + this.enemy_head_y);
// System.out.println("Targets - " + targets);
for (Tile target : targets) {
LinkedList<Tile> path = this.dk.path(us_tile, target, this.gb);
if (path != null) { // means we couldn't reach the desired target
// System.out.println("Path - " + path);
if (shortestPath == null) {
shortestPath = path;
} else if (path.size() < shortestPath.size()) {
shortestPath = path;
}
}
}
// System.out.println("Shortest Path - " + shortestPath);
if (shortestPath == null) return us_tile;
return shortestPath.get(1);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void targetLostResponse(){\n\t\tswitch(state){\r\n\t\tcase(PURSUIT):\r\n\t\t\tstate=HUNTING;\r\n\t\t\tTile[] targetChoices=adjacentUnseenTiles(level(),targetTile);\r\n\t\t\tif(targetChoices[0]==null)\r\n\t\t\t\tstate=IDLE;\r\n\t\t\ttargetLostResponse();\r\n\t\t\tbreak;\r\n\t\tcase(HUNTING):\t//TODO: after ... | [
"0.6582824",
"0.6543927",
"0.64969707",
"0.6382267",
"0.6323258",
"0.63198406",
"0.62595713",
"0.625769",
"0.6253198",
"0.61674047",
"0.61625427",
"0.6119706",
"0.60443205",
"0.6017288",
"0.6017098",
"0.6011583",
"0.60100245",
"0.5999143",
"0.5994347",
"0.59731793",
"0.595513... | 0.0 | -1 |
Find targets 2 spots away from the enemy snake's head | public List<Tile> findTargets() {
List<Tile> targets = new ArrayList<>(); // our return value
int fearDistance = 2; // Ideally we're 2 spots away from their head, increases when we can't do that.
int foodDistance = 3; // We look at a distance 3 for food.
// If fearDistance gets this big, then its just GG i guess
while (targets.size() == 0 && fearDistance < 15) {
// Get the tiles around the Enemy's head
targets = this.gb.nearByTiles(this.enemy_head_x, this.enemy_head_y, fearDistance);
fearDistance += 1;
}
// Get the food tiles near us
for (int i=0; i < foodDistance; i++) {
List<Tile> nearBy = this.gb.nearByTiles(this.us_head_x, this.us_head_y, i);
for (Tile t : nearBy) {
if (t.isFood() && !targets.contains(t)) targets.add(t);
}
}
return targets;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void findEnemySnake() {\n // Cheap fix to GameState spawning a food on a person's HeadPiece\n if (this.gb.heads.size() == 1) {\n if (print) System.out.println(\" ONLY 1 HEAD FOUND IN GAME BOARD!\");\n HeadPiece h1 = this.gb.heads.get(0);\n if ((h1.getX() == thi... | [
"0.6350167",
"0.6016832",
"0.59310204",
"0.59078693",
"0.59077966",
"0.5856197",
"0.5852436",
"0.58374375",
"0.58325934",
"0.5817191",
"0.5796935",
"0.5740817",
"0.5688893",
"0.5670011",
"0.5649649",
"0.5622473",
"0.5617024",
"0.5614631",
"0.55903065",
"0.55620146",
"0.553824... | 0.64650494 | 0 |
Find the enemy snake head | public void findEnemySnake() {
// Cheap fix to GameState spawning a food on a person's HeadPiece
if (this.gb.heads.size() == 1) {
if (print) System.out.println(" ONLY 1 HEAD FOUND IN GAME BOARD!");
HeadPiece h1 = this.gb.heads.get(0);
if ((h1.getX() == this.us_head_x) && (h1.getY() == this.us_head_y)) {
// fucking panic i guess
if (print) System.out.println(" CANNOT FIND ENEMY HEAD?????");
this.enemy_head_x = 0;
this.enemy_head_y = 0;
} else {
// Correctly found enemy head
this.enemy_head_x = h1.getX();
this.enemy_head_y = h1.getY();
}
return;
}
// Find the enemy snake head and update member variables
HeadPiece h1 = this.gb.heads.get(0);
HeadPiece h2 = this.gb.heads.get(1);
HeadPiece enemyHead;
if ((h1.getX() == this.us_head_x) && (h1.getY() == this.us_head_y)) {
enemyHead = h2;
} else {
enemyHead = h1;
}
this.enemy_head_x = enemyHead.getX();
this.enemy_head_y = enemyHead.getY();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public XYPoint getSnakeHeadStartLocation();",
"public Pair GetHead() {\n return snake.get(head);\n }",
"public HeadComponent getHead() {\n\t\treturn (HeadComponent) snake.getLast();\n\t}",
"Entity getShooter();",
"public int move(String direction) {\n int h = snake.getFirst() / width, w = snak... | [
"0.69583154",
"0.6204184",
"0.60545534",
"0.6016989",
"0.5780173",
"0.5698064",
"0.5684204",
"0.55440444",
"0.55299795",
"0.54592615",
"0.5425525",
"0.5326194",
"0.5312011",
"0.52853817",
"0.5271591",
"0.52582896",
"0.5253566",
"0.52444077",
"0.52163863",
"0.52105767",
"0.520... | 0.75879246 | 0 |
Constructs a new CaseInsensitiveElementList. | public CaseInsensitiveElementList() {
this((Locale)null);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CaseInsensitiveElementList(IData document) {\n this(document, null);\n }",
"public CaseInsensitiveElementList(Collection<Element<String, V>> collection) {\n this(collection, null);\n }",
"public CaseInsensitiveElementList(Locale locale) {\n setLocale(locale);\n }",
"publi... | [
"0.7428875",
"0.7324687",
"0.7201247",
"0.6917796",
"0.6791029",
"0.66955525",
"0.6646956",
"0.6601417",
"0.63502586",
"0.5945697",
"0.5936464",
"0.5808463",
"0.5744695",
"0.5709118",
"0.5481269",
"0.54166496",
"0.53931254",
"0.53763294",
"0.53587186",
"0.53118443",
"0.515632... | 0.82276154 | 0 |
Constructs a new CaseInsensitiveElementList. | public CaseInsensitiveElementList(Locale locale) {
setLocale(locale);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CaseInsensitiveElementList() {\n this((Locale)null);\n }",
"public CaseInsensitiveElementList(IData document) {\n this(document, null);\n }",
"public CaseInsensitiveElementList(Collection<Element<String, V>> collection) {\n this(collection, null);\n }",
"public static IDa... | [
"0.8226578",
"0.74280584",
"0.7324199",
"0.69177467",
"0.6788912",
"0.66934",
"0.66464233",
"0.66016847",
"0.6348187",
"0.5947875",
"0.59351075",
"0.580599",
"0.5741958",
"0.57086295",
"0.5474885",
"0.54170036",
"0.53927946",
"0.537897",
"0.5357404",
"0.53118616",
"0.5154269"... | 0.72010374 | 3 |
Constructs a new CaseInsensitiveElementList seeded with the elements in the given IData document. | public CaseInsensitiveElementList(IData document) {
this(document, null);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CaseInsensitiveElementList(IData document, Locale locale) {\n this(locale);\n addAll(document);\n }",
"public CaseInsensitiveElementList() {\n this((Locale)null);\n }",
"public CaseInsensitiveElementListIDataCursor() {\n initialize();\n }",
"public static I... | [
"0.7555705",
"0.7055482",
"0.7049486",
"0.69365394",
"0.69044274",
"0.67491466",
"0.6429329",
"0.6357144",
"0.6060375",
"0.5939912",
"0.5883071",
"0.5716959",
"0.5496495",
"0.53512424",
"0.50657964",
"0.49914673",
"0.49575338",
"0.49350837",
"0.49307507",
"0.47261313",
"0.469... | 0.8431594 | 0 |
Constructs a new CaseInsensitiveElementList seeded with the elements in the given IData document. | public CaseInsensitiveElementList(IData document, Locale locale) {
this(locale);
addAll(document);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CaseInsensitiveElementList(IData document) {\n this(document, null);\n }",
"public CaseInsensitiveElementList() {\n this((Locale)null);\n }",
"public CaseInsensitiveElementListIDataCursor() {\n initialize();\n }",
"public static IData create() {\n return ne... | [
"0.84319144",
"0.7054987",
"0.7049121",
"0.69355726",
"0.6904063",
"0.6748179",
"0.64295256",
"0.6356644",
"0.6060381",
"0.59396976",
"0.58825254",
"0.5716812",
"0.54970586",
"0.5351331",
"0.5065302",
"0.49913773",
"0.4957574",
"0.49348572",
"0.4932062",
"0.47254232",
"0.4694... | 0.75552756 | 1 |
Constructs a new CaseInsensitiveElementList seeded with the elements in the given Map. | public CaseInsensitiveElementList(Map<String, ? extends V> map) {
this(map, null);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CaseInsensitiveElementList(Map<String, ? extends V> map, Locale locale) {\n this(locale);\n addAll(map);\n }",
"public CaseInsensitiveElementList() {\n this((Locale)null);\n }",
"public CaseInsensitiveElementList(IData document) {\n this(document, null);\n }",
"pub... | [
"0.77542573",
"0.67203885",
"0.62882245",
"0.61923563",
"0.61694247",
"0.61037314",
"0.59147966",
"0.56251234",
"0.5621375",
"0.5480092",
"0.5285151",
"0.5269911",
"0.5170866",
"0.5145869",
"0.4945162",
"0.48576748",
"0.47924602",
"0.47725487",
"0.4770352",
"0.47427016",
"0.4... | 0.83454347 | 0 |
Constructs a new CaseInsensitiveElementList seeded with the elements in the given Map. | public CaseInsensitiveElementList(Map<String, ? extends V> map, Locale locale) {
this(locale);
addAll(map);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CaseInsensitiveElementList(Map<String, ? extends V> map) {\n this(map, null);\n }",
"public CaseInsensitiveElementList() {\n this((Locale)null);\n }",
"public CaseInsensitiveElementList(IData document) {\n this(document, null);\n }",
"public CaseInsensitiveElementList(Loc... | [
"0.8345722",
"0.6720241",
"0.6288552",
"0.61917335",
"0.6168879",
"0.61032194",
"0.5913862",
"0.5627215",
"0.5622196",
"0.54816484",
"0.5286173",
"0.5268971",
"0.5171335",
"0.5146623",
"0.49456856",
"0.48580518",
"0.47935748",
"0.4774257",
"0.47715345",
"0.47424",
"0.47223175... | 0.77537906 | 1 |
Constructs a new CaseInsensitiveElementList seeded with the elements in the given Collection. | public CaseInsensitiveElementList(Collection<Element<String, V>> collection) {
this(collection, null);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CaseInsensitiveElementList(Collection<Element<String, V>> collection, Locale locale) {\n this(locale);\n addAll(collection);\n }",
"public CaseInsensitiveElementList() {\n this((Locale)null);\n }",
"public CaseInsensitiveElementList(Locale locale) {\n setLocale(locale);... | [
"0.7844025",
"0.7030773",
"0.64288473",
"0.638246",
"0.63713044",
"0.62004685",
"0.5912249",
"0.57512826",
"0.57318676",
"0.5638921",
"0.5559636",
"0.5534602",
"0.54699206",
"0.54523027",
"0.54483294",
"0.53427994",
"0.53152066",
"0.5307068",
"0.5300681",
"0.5276841",
"0.5183... | 0.8447048 | 0 |
Constructs a new CaseInsensitiveElementList seeded with the elements in the given Collection. | public CaseInsensitiveElementList(Collection<Element<String, V>> collection, Locale locale) {
this(locale);
addAll(collection);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CaseInsensitiveElementList(Collection<Element<String, V>> collection) {\n this(collection, null);\n }",
"public CaseInsensitiveElementList() {\n this((Locale)null);\n }",
"public CaseInsensitiveElementList(Locale locale) {\n setLocale(locale);\n }",
"public ListMemberCons... | [
"0.84462655",
"0.70306075",
"0.64293265",
"0.6383856",
"0.6371718",
"0.62011397",
"0.59124494",
"0.57511127",
"0.5731856",
"0.5639992",
"0.55594414",
"0.5537056",
"0.54700744",
"0.545233",
"0.5448276",
"0.5342515",
"0.5313591",
"0.5307793",
"0.5302373",
"0.5276656",
"0.518277... | 0.78434205 | 1 |
Sets the locale to use for case comparison. | protected void setLocale(Locale locale) {
this.locale = LocaleHelper.normalize(locale);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setLocale (\r\n String strLocale) throws java.io.IOException, com.linar.jintegra.AutomationException;",
"public void setPreferredLocale(Locale locale);",
"public void setLocale(Locale locale) {\n fLocale = locale;\n }",
"public void setRequestedLocale(final Locale val) {... | [
"0.6556668",
"0.64890504",
"0.64327896",
"0.6405116",
"0.63092095",
"0.62603325",
"0.62581754",
"0.6250553",
"0.6221736",
"0.62108886",
"0.62030727",
"0.6190135",
"0.6113028",
"0.61090404",
"0.6088137",
"0.60438216",
"0.60438216",
"0.59973025",
"0.58916914",
"0.5835874",
"0.5... | 0.58636045 | 19 |
Normalizes the given Element; this default implementation returns the given element unmodified. Subclasses can override this method to return a more appropriate Element subclass if required. | @Override
protected Element<String, V> normalize(Element<String, V> element) {
return new CaseInsensitiveElement<V>(element, locale);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void normalise() {\n\t\tElement base = this;\n\t\t\n\t\tbase.setNamespace(\"1\");\n\t\t\n\t\tint i = 1;\n\t\tfor (Element child : base.getAllChildren() )\n\t\t\tbase.normaliseChild(child, i++);\n\t\t\n\t\t\n\t}",
"@Nonnull\n S normalize();",
"@Override\n\tpublic Element toElement() {\n\t\treturn null;\... | [
"0.64026314",
"0.6129516",
"0.60103124",
"0.5889421",
"0.5873819",
"0.5799886",
"0.5699565",
"0.5344725",
"0.5215568",
"0.52002877",
"0.5187377",
"0.51650685",
"0.5143655",
"0.51191956",
"0.5112354",
"0.50937396",
"0.5087304",
"0.50813854",
"0.5038673",
"0.5033163",
"0.503316... | 0.6490881 | 0 |
Normalizes the given IData; this implementation converts the IData to an ElementList. Subclasses should override this method and return an instance of their self. | @Override
protected IData normalize(IData document) {
return new CaseInsensitiveElementList<Object>(document);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Collection<Element> getElementTreeFromPlainList() {\n Map<String, Element> values = new HashMap<String, Element>();\n for (String[] s : data) {\n values.put(s[0], new Element(s[2], s[1]));\n }\n\n // creates a result list\n Collection<Element> result = new ArrayList<El... | [
"0.5995944",
"0.5995944",
"0.5767445",
"0.55771524",
"0.5511548",
"0.5446172",
"0.52799153",
"0.5251928",
"0.5245896",
"0.5152162",
"0.5111908",
"0.51095194",
"0.50999486",
"0.5073334",
"0.5049907",
"0.49378848",
"0.49186036",
"0.49059525",
"0.49015254",
"0.48860765",
"0.4869... | 0.67259395 | 0 |
Returns a newly created IData object. | public static IData create() {
return new CaseInsensitiveElementList<Object>();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected abstract D createData();",
"DataElement createDataElement();",
"public InternalData createInternalData2() {\r\n return new InternalData(); // returns data which is not exported from Module modb\r\n }",
"CreationData creationData();",
"DataType createDataType();",
... | [
"0.75918597",
"0.72101074",
"0.67730755",
"0.6633091",
"0.6601053",
"0.65868574",
"0.65551496",
"0.65216017",
"0.65131474",
"0.6485246",
"0.64848924",
"0.64836425",
"0.6443946",
"0.64343315",
"0.6398267",
"0.6368184",
"0.63204795",
"0.62921023",
"0.6254554",
"0.62308747",
"0.... | 0.6267753 | 18 |
Returns an IDataCursor for this IData object. An IDataCursor contains the basic methods you use to traverse an IData object and get or set elements within it. | @Override
public IDataCursor getCursor() {
return new CaseInsensitiveElementListIDataCursor();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static interface Cursor {\n\t\tpublic void open() throws RelationException;\n\n\t\t//the hasNext() method actually loads the object, so don't skip it\n\t\tpublic boolean hasNext() throws RelationException;\n\n\t\t//this retrieves the next object. use in confunction with hasNext();\n\t\tpublic Tuple next() ... | [
"0.6533227",
"0.6496294",
"0.6480046",
"0.6305573",
"0.63054436",
"0.612477",
"0.6117801",
"0.60568035",
"0.60124594",
"0.60104007",
"0.5970316",
"0.59648323",
"0.593156",
"0.5806357",
"0.57421505",
"0.57212144",
"0.564374",
"0.5575074",
"0.5567253",
"0.5565825",
"0.5522783",... | 0.6740706 | 0 |
Recursively builds a clone of the given IData document as a new CaseInsensitiveElementList. | public static IData of(IData document, Locale locale) {
return new CaseInsensitiveElementList<Object>(document, locale);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n protected IData normalize(IData document) {\n return new CaseInsensitiveElementList<Object>(document);\n }",
"public CaseInsensitiveElementList(IData document) {\n this(document, null);\n }",
"public CaseInsensitiveElementList(IData document, Locale locale) {\n this(lo... | [
"0.7156497",
"0.69368696",
"0.6152592",
"0.5786891",
"0.5518731",
"0.5495489",
"0.53091234",
"0.53091234",
"0.5307627",
"0.51869047",
"0.5098538",
"0.50603193",
"0.49058077",
"0.4816845",
"0.4734621",
"0.47305486",
"0.46901512",
"0.4683951",
"0.46518397",
"0.46303427",
"0.462... | 0.56564546 | 4 |
Recursively builds a clone of the given IData[] document list as a new CaseInsensitiveElementList[]. | public static IData[] of(IData[] documents, Locale locale) {
IData[] output = new IData[documents == null ? 0 : documents.length];
if (documents != null) {
for (int i = 0; i < documents.length; i++) {
output[i] = of(documents[i], locale);
}
}
return output;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n protected IData normalize(IData document) {\n return new CaseInsensitiveElementList<Object>(document);\n }",
"public CaseInsensitiveElementList(IData document) {\n this(document, null);\n }",
"public CaseInsensitiveElementList(IData document, Locale locale) {\n this(lo... | [
"0.6988018",
"0.67276096",
"0.5954786",
"0.56085795",
"0.5513654",
"0.5513654",
"0.54086256",
"0.5365783",
"0.52584463",
"0.5217732",
"0.5177175",
"0.5098874",
"0.49420935",
"0.49078178",
"0.48568386",
"0.4791309",
"0.47897816",
"0.47830564",
"0.46550697",
"0.46491408",
"0.46... | 0.0 | -1 |
Constructs a new cursor. | public CaseInsensitiveElementListIDataCursor() {
initialize();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public abstract Cursor buildCursor();",
"public MyCursorWrapper(Cursor cursor) {\n super(cursor);\n }",
"public CrimeCursorWrapper(Cursor cursor) {\n super(cursor);\n }",
"public BorrowerCursor(Cursor cursor) {\n super(cursor);\n }",
"public GameCursor() {\n }",
"public s... | [
"0.78976697",
"0.7117633",
"0.68738896",
"0.6648203",
"0.63155925",
"0.6311589",
"0.6271342",
"0.61225843",
"0.606397",
"0.60483646",
"0.60210896",
"0.6014658",
"0.59965163",
"0.5989282",
"0.59683573",
"0.5967269",
"0.595207",
"0.59437555",
"0.57649994",
"0.571358",
"0.570817... | 0.5225774 | 73 |
Constructs a new cursor initialized to the given position. | public CaseInsensitiveElementListIDataCursor(int position) {
initialize(position);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public abstract Cursor buildCursor();",
"public void setPosition ( TextPosition position ) throws OutOfBoundsException { _cursorPosition = position; }",
"public Builder to(int cursor){\n MathUtils.assertInRange(cursor, 0, LENGTH - 1);\n this.cursor = cursor;\n return this;\n ... | [
"0.6825151",
"0.64260346",
"0.6369599",
"0.6031318",
"0.598034",
"0.59481424",
"0.5943552",
"0.59369725",
"0.5912561",
"0.590933",
"0.5744949",
"0.57355994",
"0.573292",
"0.5699139",
"0.56888044",
"0.5639545",
"0.56257844",
"0.5590568",
"0.55891174",
"0.5561156",
"0.5559352",... | 0.6122513 | 3 |
Initializes this cursor with the given position. | protected void initialize(int position) {
iterator = listIterator();
if (position >= 0) {
for (int i = 0; i <= position; i++) {
next();
}
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setPosition ( TextPosition position ) throws OutOfBoundsException { _cursorPosition = position; }",
"public CaseInsensitiveElementListIDataCursor(int position) {\n initialize(position);\n }",
"public void init() {\n position.print();\n }",
"public POS(int position) {\n... | [
"0.67989916",
"0.6407932",
"0.6273226",
"0.6193409",
"0.61445814",
"0.61000395",
"0.60931975",
"0.6078197",
"0.6033975",
"0.60063064",
"0.6006163",
"0.5990316",
"0.59418",
"0.59260845",
"0.5903355",
"0.5892856",
"0.5888094",
"0.58817637",
"0.58776945",
"0.58576936",
"0.585376... | 0.6913159 | 0 |
Not implemented, does nothing. | public void setErrorMode(int mode) {} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public final void mo51373a() {\n }",
"public void doNothing(){\n\t}",
"@Override\n\tpublic int method() {\n\t\treturn 0;\n\t}",
"public void m23075a() {\n }",
"public final void mo91715d() {\n }",
"@Override\n public void perish() {\n \n }",
"public static void doNothing(){\n\... | [
"0.72510844",
"0.699856",
"0.6851293",
"0.68510765",
"0.68400985",
"0.6820389",
"0.6798686",
"0.6771418",
"0.6767583",
"0.67553794",
"0.67553794",
"0.6738845",
"0.6736227",
"0.6730237",
"0.67290866",
"0.66992116",
"0.66945934",
"0.6692118",
"0.6654185",
"0.66464686",
"0.66429... | 0.0 | -1 |
Not implemented, does nothing. | public DataException getLastError() {
return null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public final void mo51373a() {\n }",
"public void doNothing(){\n\t}",
"@Override\n\tpublic int method() {\n\t\treturn 0;\n\t}",
"public void m23075a() {\n }",
"public final void mo91715d() {\n }",
"@Override\n public void perish() {\n \n }",
"public static void doNothing(){\n\... | [
"0.72510844",
"0.699856",
"0.6851293",
"0.68510765",
"0.68400985",
"0.6820389",
"0.6798686",
"0.6771418",
"0.6767583",
"0.67553794",
"0.67553794",
"0.6738845",
"0.6736227",
"0.6730237",
"0.67290866",
"0.66992116",
"0.66945934",
"0.6692118",
"0.6654185",
"0.66464686",
"0.66429... | 0.0 | -1 |
Not implemented, does nothing. | public boolean hasMoreErrors() {
return false;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public final void mo51373a() {\n }",
"public void doNothing(){\n\t}",
"public void m23075a() {\n }",
"@Override\n\tpublic int method() {\n\t\treturn 0;\n\t}",
"public final void mo91715d() {\n }",
"@Override\n public void perish() {\n \n }",
"public static void doNothing(){\n\... | [
"0.7253101",
"0.6998572",
"0.6852465",
"0.68521184",
"0.6841567",
"0.68216133",
"0.6798824",
"0.6772588",
"0.67693496",
"0.6756796",
"0.6756796",
"0.6740401",
"0.6737112",
"0.67312366",
"0.67302907",
"0.6700296",
"0.6695963",
"0.66939205",
"0.6656461",
"0.6647018",
"0.6643066... | 0.0 | -1 |
Returns the key at the cursor's current position. | public String getKey() {
return element == null ? null : element.getKey();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"String getKey();",
"java.lang.String getKey();",
... | [
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.7538102",
"0.749421",
"0.749421",
"0.749421",
"0.749421",
"0.749421",
"0.749421",
"0.744254",
"0.744254",
"0.741942... | 0.0 | -1 |
Sets the key at the cursor's current position. | public void setKey(String key) {
if (element != null) {
element.setKey(key);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setKey(int key);",
"public void setKey(int key);",
"public void setKey(char key){ this.key = key;}",
"public void setKey(SelectionKey key) {\n this._key = key;\n }",
"public void setKey(int key){\r\n this.key = key; \r\n }",
"void setKey(K key);",
"public void _setKey(String... | [
"0.7256104",
"0.7256104",
"0.72398907",
"0.71630025",
"0.7087297",
"0.70859444",
"0.70858157",
"0.7073709",
"0.7045561",
"0.70316374",
"0.69605106",
"0.6921008",
"0.6880597",
"0.6880597",
"0.6872566",
"0.6858962",
"0.6857535",
"0.6850103",
"0.68250424",
"0.6808773",
"0.680677... | 0.6260957 | 49 |
Returns the value at the cursor's current position. | public Object getValue() {
return element == null ? null : element.getValue();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CursorPosition getCurrentCursorPosition(){\n return XSelection.getCurrentCursorPosition(this);\n }",
"@Override\n public E getCurrent() {\n if (isCurrent()) { return cursor.getData(); }\n else { throw new IllegalStateException(\"There is no current element.\"); }\n }",
"pub... | [
"0.7053146",
"0.6983254",
"0.6956108",
"0.68555236",
"0.6821669",
"0.6816853",
"0.67865986",
"0.6738922",
"0.6692717",
"0.66381055",
"0.66044134",
"0.6584808",
"0.65480214",
"0.6544915",
"0.6524092",
"0.6520022",
"0.6509452",
"0.6503338",
"0.6494281",
"0.64916813",
"0.6488368... | 0.0 | -1 |
Sets the value at the cursor's current position. | @SuppressWarnings("unchecked")
public void setValue(Object value) {
if (element != null) {
element.setValue((V)value);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setCurrentPosition(int value) {\n this.currentPosition = value;\n }",
"public void setValue(int val)\r\n {\r\n value = val;\r\n }",
"public void setCursor(int row, int col);",
"public void setValue(int value)\n {\n // we have assumed value 1 for X and 10 for O\n ... | [
"0.6867903",
"0.6760759",
"0.66913384",
"0.66885054",
"0.6637262",
"0.6593114",
"0.65845853",
"0.65844184",
"0.65715337",
"0.65648884",
"0.65489787",
"0.6526079",
"0.65260017",
"0.65260017",
"0.65260017",
"0.65260017",
"0.65260017",
"0.6519044",
"0.6511719",
"0.6511719",
"0.6... | 0.0 | -1 |
Deletes the element at the cursor's current position. | public boolean delete() {
boolean result = true;
try {
iterator.remove();
} catch(IllegalStateException ex) {
result = false;
}
return result;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void remove()\n {\n list.remove(cursor);\n cursor--;\n }",
"public void removeAtCursor() {\n lines.remove(cursor);\n if(cursor !=0 && cursor==lines.size())\n cursor--;\n }",
"public void delete(){\n if(currentText != null) {\n //The saved... | [
"0.6904179",
"0.68329763",
"0.6832452",
"0.6550805",
"0.6354069",
"0.6351611",
"0.6326879",
"0.63120735",
"0.6263454",
"0.626217",
"0.62514853",
"0.62407994",
"0.62288123",
"0.62084794",
"0.6175793",
"0.6157591",
"0.6157591",
"0.6157591",
"0.6050646",
"0.6042135",
"0.6032868"... | 0.0 | -1 |
Inserts the key value pair before the cursor's current position. | @SuppressWarnings("unchecked")
public void insertBefore(String key, Object value) {
previous();
iterator.add(new CaseInsensitiveElement<V>(key, (V)value));
next();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void insertBeforeCursor(String s) {\n if(this.isEmpty() || cursor==-1)\n {\n lines.addFirst(s);\n }\n else\n lines.addBefore(new PositionObject<>(lines.get(cursor)), s);\n //cursor--;\n }",
"void insert(Object value, int position);",
"public vo... | [
"0.6545065",
"0.64268446",
"0.62133974",
"0.6121285",
"0.60550725",
"0.6010797",
"0.596927",
"0.5896668",
"0.5847738",
"0.5823803",
"0.5823803",
"0.5815233",
"0.5811356",
"0.58027303",
"0.5782736",
"0.577597",
"0.5739579",
"0.56863976",
"0.56531334",
"0.5590476",
"0.5589747",... | 0.6662596 | 0 |
Inserts the key value pair after the cursor's current position. | @SuppressWarnings("unchecked")
public void insertAfter(String key, Object value) {
iterator.add(new CaseInsensitiveElement<V>(key, (V)value));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void InsertAtEnd(K pk){\n\t\tsuper.append(pk);\n\t}",
"void insert(Object value, int position);",
"public void insertAfterCursor(String s) {\n if(this.isEmpty())\n {\n lines.addFirst(s);\n }\n else\n lines.addAfter(new PositionObject<>(lines.get(cursor))... | [
"0.6654868",
"0.62627774",
"0.6085834",
"0.59265965",
"0.5804589",
"0.5800378",
"0.5779413",
"0.5779413",
"0.5762144",
"0.5732306",
"0.57293296",
"0.5705555",
"0.56491464",
"0.56444055",
"0.5596228",
"0.55599767",
"0.55170006",
"0.54969877",
"0.5477753",
"0.5457748",
"0.54546... | 0.6300298 | 1 |
Inserts the key with a new IData document before the cursor's current position. | public IData insertDataBefore(String key) {
IData data = new CaseInsensitiveElementList<V>();
insertBefore(key, data);
return data;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void insert(String key){\n DataPair dp = getDataPair(key);\n insert(dp);\n }",
"com.icare.eai.schema.om.evSORequest.EvSORequestDocument.EvSORequest.Key insertNewKey(int i);",
"public abstract boolean insert(Key key);",
"public void insert(KeyedItem newItem);",
"public void InsertAtE... | [
"0.67716634",
"0.67588603",
"0.6440841",
"0.6427346",
"0.6234466",
"0.61395544",
"0.61003757",
"0.60368985",
"0.59449494",
"0.5936355",
"0.59359705",
"0.59247357",
"0.5922982",
"0.5869519",
"0.5853302",
"0.58380353",
"0.5836353",
"0.57752454",
"0.57520634",
"0.575014",
"0.574... | 0.615795 | 5 |
Inserts the key with a new IData document after the cursor's current position. | public IData insertDataAfter(String key) {
IData data = new CaseInsensitiveElementList<V>();
insertAfter(key, data);
return data;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"com.icare.eai.schema.om.evSORequest.EvSORequestDocument.EvSORequest.Key insertNewKey(int i);",
"public void insert(String key){\n DataPair dp = getDataPair(key);\n insert(dp);\n }",
"public void InsertAtEnd(K pk){\n\t\tsuper.append(pk);\n\t}",
"public void insert(KeyedItem newItem);",
"pub... | [
"0.67199457",
"0.6555589",
"0.6522243",
"0.6443879",
"0.62884605",
"0.5984308",
"0.5900755",
"0.58841246",
"0.58339435",
"0.57768285",
"0.5757824",
"0.5709749",
"0.5683006",
"0.56601846",
"0.5650625",
"0.56494266",
"0.5644727",
"0.5637133",
"0.56266487",
"0.5621594",
"0.56072... | 0.59435564 | 6 |
Repositions this cursor's on the next element. | public boolean next() {
boolean result = true;
try {
element = iterator.next();
} catch(NoSuchElementException ex) {
result = false;
}
return result;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void advance( )\r\n {\r\n\t if(isCurrent() != true){// Implemented by student.\r\n\t throw new IllegalStateException(\"no current element\");\r\n\t }\r\n\t else\r\n\t \t precursor = cursor;\r\n\t \t cursor = cursor.getLink(); // Implemented by student.\r\n }",
"@Override\n... | [
"0.7761292",
"0.7595016",
"0.7355598",
"0.7039067",
"0.66453475",
"0.6624353",
"0.65508825",
"0.65074223",
"0.6466183",
"0.6454243",
"0.635951",
"0.6334268",
"0.632952",
"0.6262397",
"0.6232246",
"0.6217547",
"0.6196411",
"0.61949515",
"0.6174354",
"0.61689687",
"0.6162328",
... | 0.0 | -1 |
Repositions this cursor's on the next occurrence of the given key. | public boolean next(String key) {
while(next()) {
if (element.keyEquals(new CaseInsensitiveElement<V>(key, null))) return true;
}
return false;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void inc(String key) {\n int val = 0;\n\n if (!m.containsKey(key)) {\n m.put(key, val + 1);\n } else {\n val = m.get(key);\n m.put(key, val + 1);\n delete(key, val);\n }\n\n insert(key, val + 1);\n }",
"public void setRowKey... | [
"0.6296332",
"0.62312984",
"0.617595",
"0.6047586",
"0.6022671",
"0.6001179",
"0.5823138",
"0.58132535",
"0.57979524",
"0.56533974",
"0.5643725",
"0.5571737",
"0.5570943",
"0.55621463",
"0.5531793",
"0.55242884",
"0.55122215",
"0.5428208",
"0.53811526",
"0.53479725",
"0.53282... | 0.0 | -1 |
Repositions this cursor's on the previous element. | public boolean previous() {
boolean result = true;
try {
element = iterator.previous();
} catch(NoSuchElementException ex) {
result = false;
}
return result;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void previous() {\n if (hasPrevious()) {\n setPosition(position - 1);\n }\n }",
"void movePrev()\n\t{\n\t\tif (cursor != null) \n\t\t{\n\t\t\tif (cursor == front) \n\t\t\t{\n\t\t\t\tcursor = null;\n index = -1; //added this because i kept failing the test cases o... | [
"0.7910565",
"0.7697611",
"0.73398805",
"0.73294884",
"0.7156966",
"0.7056169",
"0.7046098",
"0.6853121",
"0.6839226",
"0.6774662",
"0.6757567",
"0.6757081",
"0.66409665",
"0.65907776",
"0.6588324",
"0.65300196",
"0.6526085",
"0.65190333",
"0.6514188",
"0.64943224",
"0.648556... | 0.0 | -1 |
Repositions this cursor's on the previous occurrence of the given key. | public boolean previous(String key) {
while(previous()) {
if (element.equals(new CaseInsensitiveElement<V>(key, null))) return true;
}
return false;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void Previous(int key){\n\t\tif(search(key)!=nil){\n\t\t\tNode res = getPrev(root,key,nil);\n\t\t\tif(res != nil){\n\t\t\t\tSystem.out.println(res.id + \" \" + res.count);\n\t\t\t}else{\n\t\t\t\tSystem.out.println(\"0 0\");\n\t\t\t}\n\t\t}else{\n\t\t\tint prev = findPrev(root,key);\n\t\t\tNode res = getNode... | [
"0.63764834",
"0.61273",
"0.60970575",
"0.60047585",
"0.5964809",
"0.5955955",
"0.5878971",
"0.58100545",
"0.57876855",
"0.57388693",
"0.5717333",
"0.5702541",
"0.5645561",
"0.5585812",
"0.55534",
"0.54928464",
"0.54646635",
"0.5418329",
"0.53925663",
"0.5368441",
"0.536823",... | 0.5414013 | 18 |
Repositions this cursor's on the first element. | public boolean first() {
initialize();
return next();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void moveFirst() {\n\t\tcurrentElement = 0;\n\t}",
"public void firstElement() {\r\n \t\tcurrentObject = 0;\r\n \t}",
"public void beforeFirst() {\n\t\tmoveTo(0);\n\t}",
"void moveFront()\n\t{\n\t\tif (length != 0)\n\t\t {\n\t\t\tcursor = front;\n\t\t\tindex = 0; //cursor will be at the front\n\t\t\t\... | [
"0.7543401",
"0.6987902",
"0.68785024",
"0.67250645",
"0.6499319",
"0.6494836",
"0.64203876",
"0.641393",
"0.63739675",
"0.6305814",
"0.62827426",
"0.6259256",
"0.62283874",
"0.62204295",
"0.6171929",
"0.61341095",
"0.6101193",
"0.60974485",
"0.60950506",
"0.60896266",
"0.607... | 0.0 | -1 |
Repositions this cursor's on the first occurrence of the given key. | public boolean first(String key) {
initialize();
return next(key);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setRowKey(Object key)\n {\n if (key == null)\n {\n setRowIndex(-1);\n return;\n }\n\n if (getRowKey() != null && getRowKey().equals(key))\n return;\n \n for (int i = 0; i < getRowCount(); i++)\n {\n setRowIndex(i);\n Object prop = getRowKey();\n if (k... | [
"0.6410121",
"0.6126454",
"0.5974966",
"0.58527",
"0.5607304",
"0.55506337",
"0.55333716",
"0.546483",
"0.5421819",
"0.53959954",
"0.5395757",
"0.53860074",
"0.53794295",
"0.5339371",
"0.533476",
"0.5312218",
"0.5283996",
"0.52652794",
"0.5260687",
"0.5254652",
"0.5237527",
... | 0.48194835 | 90 |
Repositions this cursor's on the last element. | public boolean last() {
boolean result = false;
while(iterator.hasNext()) {
result = true;
next();
}
return result;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void MoveLast()\r\n {\r\n\r\n \t try{\r\n \t\t rsTution.last();\r\n \t\t Display();\r\n\r\n\r\n \t }catch(SQLException sqle)\r\n \t {System.out.println(\"MoveLast Error:\"+sqle);}\r\n \t}",
"private void setLast() { this._last = true; }",
"void seekToLast();",
"public void moveR... | [
"0.6685716",
"0.6634527",
"0.6602752",
"0.651457",
"0.64809465",
"0.6342643",
"0.6319621",
"0.63175577",
"0.6310045",
"0.6234149",
"0.6234126",
"0.623122",
"0.62232816",
"0.6211544",
"0.6179932",
"0.6155363",
"0.6137947",
"0.6077708",
"0.6067768",
"0.6042363",
"0.6013526",
... | 0.0 | -1 |
Repositions this cursor's on the last occurrence of the given key. | public boolean last(String key) {
last();
previous(key);
return next();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void addLast(int key)\r\n {\r\n if(numItems < maxSize)\r\n {\r\n mArray[numItems] = key;\r\n numItems++;\r\n }\r\n\r\n }",
"protected void setSearchKey(Key key)\n\t{\n\t\tint last_idx = _searchKeyList.size() - 1 ;\n\t\t_searchKeyList.set(last_idx, key) ;\n\... | [
"0.58034885",
"0.5787397",
"0.5622031",
"0.5489226",
"0.5452881",
"0.5423385",
"0.5329035",
"0.5286483",
"0.51953477",
"0.5188331",
"0.5176001",
"0.51747173",
"0.51668304",
"0.5135837",
"0.5133453",
"0.51182055",
"0.5109801",
"0.5093826",
"0.50903445",
"0.50824594",
"0.507446... | 0.55399346 | 3 |
Returns true if this cursor has more data to be iterated over. | public boolean hasMoreData() {
return iterator.hasNext();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public boolean hasMore() {\n if (currentCursor != null && !NULL.equalsIgnoreCase(currentCursor)) {\n return true;\n } else {\n return false;\n }\n }",
"@Override\n\t\tpublic boolean hasMoreElements() {\n\t\t\treturn cursor != size();\n\t\t}",
"private boolean isThe... | [
"0.84877515",
"0.7886905",
"0.78560233",
"0.78451985",
"0.7788912",
"0.77407646",
"0.77361155",
"0.77361155",
"0.7661228",
"0.7578902",
"0.7436663",
"0.73871887",
"0.7363116",
"0.7363078",
"0.73577374",
"0.7344688",
"0.73363847",
"0.733465",
"0.7285001",
"0.72757864",
"0.7273... | 0.8717077 | 0 |
Returns a clone of this cursor. | public IDataCursor getCursorClone() {
return new CaseInsensitiveElementListIDataCursor(this.position);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Object clone(){\n \t\n \treturn this;\n \t\n }",
"public Object clone() {\n return this.copy();\n }",
"public Object clone()\n {\n PSRelation copy = new PSRelation(new PSCollection(m_keyNames.iterator()),\n new PSCollection(m_keyValues.iterator()));\n \n copy.... | [
"0.7202379",
"0.7103724",
"0.69377863",
"0.6919166",
"0.6904711",
"0.68521315",
"0.6835365",
"0.67236257",
"0.67202675",
"0.67202675",
"0.67202675",
"0.67202675",
"0.67154056",
"0.668998",
"0.6673678",
"0.66667116",
"0.66667116",
"0.6635035",
"0.66242003",
"0.66207886",
"0.65... | 0.73965096 | 0 |
Simple server main function: | public static void main(String[] args) {
int port = 5000;
Server server = new Server(port);
//Start the server thread:
server.start();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static void main(String[] args) {\n Server server = new Server(1234);\n server.listen();\n \n // YOUR CODE HERE\n // It is not required (or recommended) to implement the server in\n // this runner class.\n }",
"public static void main(String[] args) {\n\... | [
"0.83141404",
"0.7942366",
"0.785935",
"0.78078276",
"0.779505",
"0.7774306",
"0.7757288",
"0.7750284",
"0.77223086",
"0.76988983",
"0.76591176",
"0.76575357",
"0.76151246",
"0.75830126",
"0.75807744",
"0.7556788",
"0.7547722",
"0.75277823",
"0.74876565",
"0.74698603",
"0.746... | 0.7752312 | 7 |
create HashMap to store String keys and Integer values | public static void main(String[] args) {
Map<Character, Integer> myMap = new HashMap<>();
createMap(myMap); // create map based on user input
displayMap(myMap); // display map content
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static void main(String[] args) \r\n {\n TreeMap<Employee, Integer> hashMap = new TreeMap<Employee, Integer>(); \r\n \r\n // Mapping string values to int keys \r\n hashMap.put(new Employee(10,\"uday\"), 10); \r\n hashMap.put(new Employee(11,\"uday\"), 11); \r\n hashMap... | [
"0.63421553",
"0.63050014",
"0.6302579",
"0.62385386",
"0.6217946",
"0.6049259",
"0.6039015",
"0.5983156",
"0.59687215",
"0.59533584",
"0.5943251",
"0.5940284",
"0.59341425",
"0.5901945",
"0.58370805",
"0.5814252",
"0.58026993",
"0.5781351",
"0.5725807",
"0.57252556",
"0.5720... | 0.0 | -1 |
create map from user input | private static void createMap(Map<Character, Integer> map) {
Scanner scanner = new Scanner(System.in); // create scanner
System.out.println("Enter a string:"); // prompt for user input
String input = scanner.nextLine();
char[] chars = input.replace(" ", "").toCharArray();
for (Character chr : chars) {
if (map.containsKey(chr)) {
int count = map.get(chr); // get current count
map.put(chr, count + 1); // increment count
} else
map.put(chr, 1); // add new char with a count of 1 to map
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static void main(String[] args) {\n Map<Character, Integer> myMap = new HashMap<>();\n\n createMap(myMap); // create map based on user input\n displayMap(myMap); // display map content\n }",
"public static void main(String[] args) {\n\t\tScanner scanner = new Scanner(System.in);\n\... | [
"0.71507883",
"0.6558304",
"0.6418451",
"0.63594806",
"0.635093",
"0.6296817",
"0.6270702",
"0.62454516",
"0.6238263",
"0.6233353",
"0.62238204",
"0.61098766",
"0.6105244",
"0.5986947",
"0.59865445",
"0.59734935",
"0.5916038",
"0.5911574",
"0.5898275",
"0.5891525",
"0.5853123... | 0.66742617 | 1 |
liste pour contenir les client | public MorpionServerImpl() throws RemoteException {
morpionClients = new HashMap<String, MorpionClientInterface>();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void listaClient() {\n\t\t\r\n\t\tthis.listaClient.add(cliente);\r\n\t}",
"@Override\n\t\tpublic List<Client> listeClient() {\n\t\t\treturn null;\n\t\t}",
"public List<Clients> getallClients();",
"public List<Client> getAllClient();",
"public void printClientList(){\n for(String client : cli... | [
"0.8210986",
"0.8105118",
"0.81048244",
"0.7971518",
"0.7826216",
"0.75661224",
"0.7558716",
"0.754759",
"0.7546266",
"0.7505712",
"0.7498583",
"0.7466111",
"0.74247146",
"0.74171543",
"0.73976225",
"0.73886305",
"0.7360326",
"0.73402435",
"0.7339157",
"0.73252577",
"0.730705... | 0.0 | -1 |
TODO Autogenerated method stub | @Override
public String echo() throws RemoteException {
return "Hola";
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.66708666",
"0.65675074",
"0.65229905",
"0.6481001",
"0.64770633",
"0.64584893",
"0.6413091",
"0.63764185",
"0.6275735",
"0.62541914",
"0.6236919",
"0.6223816",
"0.62017626",
"0.61944294",
"0.61944294",
"0.61920846",
"0.61867654",
"0.6173323",
"0.61328775",
"0.61276996",
"0... | 0.0 | -1 |
on supprime un client de la liste morpionClients | @Override
public synchronized void leaveMorpion(String id) throws RemoteException {
this.morpionClients.remove(id);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void listaClient() {\n\t\t\r\n\t\tthis.listaClient.add(cliente);\r\n\t}",
"public void AfficherListClient() throws Exception{\n laListeClient = Client_Db_Connect.tousLesClients();\n laListeClient.forEach((c) -> {\n modelClient.addRow(new Object[]{ c.getIdent(),\n ... | [
"0.78748906",
"0.7313043",
"0.7302204",
"0.7153981",
"0.69477427",
"0.68830776",
"0.6834504",
"0.67750543",
"0.6712481",
"0.6695018",
"0.6690775",
"0.6680899",
"0.66785675",
"0.66772455",
"0.6665369",
"0.6651634",
"0.659249",
"0.65372545",
"0.6501261",
"0.6484057",
"0.6475771... | 0.0 | -1 |
TODO Autogenerated method stub | @Override
public int compare(NjRepayOfflineLine o1, NjRepayOfflineLine o2) {
return (int) (o1.getPlanRepayDay().getTime() - o2.getPlanRepayDay().getTime());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.608016... | 0.0 | -1 |
Invoked when a sale has been paid | void newSale(double totalWithTaxes); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void completeSale() {\n\n }",
"void purchaseMade();",
"@Override\n public void newSale(double payment) {\n calculateTotalRevenue(payment);\n showTotalRevenue();\n }",
"public void bookSale(Sale sale)\n {\n //books the sale\n }",
"public void onPayClick(){\n ... | [
"0.7135014",
"0.70712656",
"0.68420315",
"0.67116857",
"0.6559208",
"0.65413123",
"0.645202",
"0.6434786",
"0.6421389",
"0.63806593",
"0.6380035",
"0.6323928",
"0.6291667",
"0.6289196",
"0.6288248",
"0.62731844",
"0.6208413",
"0.61759275",
"0.6151501",
"0.6150414",
"0.6140405... | 0.62312853 | 16 |
Information about a field or field set. | @Beta
public interface FieldInfo {
/** Returns the name of this field or field set. */
String name();
Field.Type type();
/** Returns whether this field or field set is attribute(s), i.e. does indexing: attribute. */
boolean isAttribute();
/** Returns whether this field is index(es), i.e. does indexing: index. */
boolean isIndex();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Set<FieldInfo> getFieldInfos() {\n return new LinkedHashSet<FieldInfo>(_atts);\n }",
"public boolean hasInfo() {\n return fieldSetFlags()[6];\n }",
"java.lang.String getFields();",
"public HashMap<String, String> getFields() {\r\n \t\treturn fields;\r\n \t}",
"public InformationFie... | [
"0.7079818",
"0.64488417",
"0.6361534",
"0.62971926",
"0.61893684",
"0.6148697",
"0.614478",
"0.60409904",
"0.60064614",
"0.59898466",
"0.59474623",
"0.5933067",
"0.59235185",
"0.59110135",
"0.5904416",
"0.5890655",
"0.5888066",
"0.5878751",
"0.5875129",
"0.58683157",
"0.5866... | 0.69943815 | 1 |
Returns the name of this field or field set. | String name(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String getName(){\n return field.getName();\n }",
"public String getFieldName() {\n int index = getFieldIndex();\n if (index == 0)\n return null;\n\n ComplexEntry entry = (ComplexEntry) getPool().getEntry(index);\n String name = entry.getNameAndTypeEntry().... | [
"0.76812613",
"0.7416612",
"0.73597413",
"0.7343566",
"0.7321095",
"0.727158",
"0.7215345",
"0.71725094",
"0.71553683",
"0.7099737",
"0.7079519",
"0.70585847",
"0.7056569",
"0.7056569",
"0.7056569",
"0.703954",
"0.7036142",
"0.7004507",
"0.6989074",
"0.6942088",
"0.6930864",
... | 0.0 | -1 |
Returns whether this field or field set is attribute(s), i.e. does indexing: attribute. | boolean isAttribute(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public boolean isAttribute() {\n\t\treturn false;\n\t}",
"@Override\n public boolean isAttribute()\n {\n return attribute;\n }",
"boolean hasAttributes();",
"boolean hasAttributes();",
"boolean isAttribute(Object object);",
"public boolean isSetAttrs() {\n return this.attrs != null;\n ... | [
"0.74385816",
"0.74135554",
"0.7163578",
"0.7163578",
"0.714304",
"0.6917586",
"0.6892651",
"0.6876824",
"0.67319506",
"0.6691353",
"0.66420823",
"0.6503704",
"0.64903355",
"0.6376298",
"0.63755226",
"0.6356126",
"0.63428766",
"0.6335149",
"0.6301553",
"0.62667626",
"0.624838... | 0.8056561 | 0 |
Returns whether this field is index(es), i.e. does indexing: index. | boolean isIndex(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public boolean isIndexed()\n {\n //only when criterion is indexed but not required it will be considered as indexed\n return (_attrDef.isIndexed() && !_attrDef.isMandatory());\n }",
"boolean isIndexed();",
"boolean isIndexed();",
"boolean getIsIndexOnKeys();",
"public boolean isIndex() { re... | [
"0.7834624",
"0.7767989",
"0.7767989",
"0.7531244",
"0.7460993",
"0.7262016",
"0.71136254",
"0.71136254",
"0.71136254",
"0.71136254",
"0.71136254",
"0.71136254",
"0.7074584",
"0.7010117",
"0.7007163",
"0.69493806",
"0.6918026",
"0.69141614",
"0.68922484",
"0.688796",
"0.68508... | 0.7764412 | 3 |
priority queue implemented by minheap under the hood | public static UniformCostSearchNode search(UniformCostSearchNode root){
PriorityQueue<UniformCostSearchNode> frontier = new PriorityQueue<UniformCostSearchNode>();
// hash set for fast verification of closed nodes
HashSet<UniformCostSearchNode> closed = new HashSet<UniformCostSearchNode>();
closed.add(root);
frontier.add(root);
while(frontier.size() != 0){
UniformCostSearchNode current = frontier.remove();
if(current.isGoalState()){
System.out.println("UCS Nodes explored: " + closed.size());
return current;
}
for(UniformCostSearchNode neighbor : current.getNeighbors()){
if(!closed.contains(neighbor)) {
if (!frontier.contains(neighbor)) {
frontier.add(neighbor);
}
}
}
}
System.out.println("UCS Search failed, nodes explored: " + closed.size());
// search failed
return null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static void main(String[] args) {\nPriorityQueue pq= new PriorityQueue(15);//,new MyComparator123());\r\nSystem.out.println(pq.peek());\r\n//System.out.println(pq.element());\r\n/*for(int i=1;i<=10;i++)\r\npq.offer(i);\r\nSystem.out.println(pq);\r\nSystem.out.println(pq.poll());\r\n\r\nSystem.out.println(pq... | [
"0.747135",
"0.7299061",
"0.71208715",
"0.69922626",
"0.69811624",
"0.6953288",
"0.6928032",
"0.68946046",
"0.68912876",
"0.6867241",
"0.68188465",
"0.6801633",
"0.6771279",
"0.67590094",
"0.67457527",
"0.67337245",
"0.67223",
"0.6713903",
"0.6694499",
"0.6628203",
"0.6619789... | 0.0 | -1 |
priority queue implemented by minheap under the hood | public static UniformCostSearchNode searchBnB(UniformCostSearchNode root){
PriorityQueue<UniformCostSearchNode> frontier = new PriorityQueue<UniformCostSearchNode>();
// hash set for fast verification of closed nodes
HashSet<UniformCostSearchNode> closed = new HashSet<UniformCostSearchNode>();
int upperBoundCost = Integer.MAX_VALUE;
frontier.add(root);
while(frontier.size() != 0){
UniformCostSearchNode current = frontier.remove();
if(current.isGoalState()){
System.out.println("UCS B&B Nodes explored: " + closed.size());
return current;
}
// implicitly pruning the frontier
if(current.getCost() >= upperBoundCost){
// skipping due to bounding
continue;
}
closed.add(current);
PriorityQueue<UniformCostSearchNode> toAdd = new PriorityQueue<UniformCostSearchNode>();
for(UniformCostSearchNode neighbor : current.getNeighbors()){
toAdd.add(neighbor);
}
while(toAdd.size() != 0) {
UniformCostSearchNode neighbor = toAdd.remove();
if (neighbor.getCost() < upperBoundCost) {
if (neighbor.isGoalState()) {
// bounding
upperBoundCost = neighbor.getCost();
}
frontier.add(neighbor);
}
}
}
System.out.println("UCS B&B Search failed, nodes explored: " + closed.size());
// search failed
return null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static void main(String[] args) {\nPriorityQueue pq= new PriorityQueue(15);//,new MyComparator123());\r\nSystem.out.println(pq.peek());\r\n//System.out.println(pq.element());\r\n/*for(int i=1;i<=10;i++)\r\npq.offer(i);\r\nSystem.out.println(pq);\r\nSystem.out.println(pq.poll());\r\n\r\nSystem.out.println(pq... | [
"0.74725634",
"0.7298183",
"0.7122129",
"0.6993857",
"0.69827896",
"0.69537544",
"0.6929447",
"0.6893875",
"0.6892684",
"0.6867427",
"0.681894",
"0.6800453",
"0.67705816",
"0.67594784",
"0.67466265",
"0.6734999",
"0.6723704",
"0.67148745",
"0.66940004",
"0.6626624",
"0.661994... | 0.0 | -1 |
method return paginated list by page/number or entity as result of filtering | @GetMapping
public Page<TeacherDTO> find(@RequestParam(required = false) Integer page, @RequestParam(required = false) Integer number,
@RequestParam(required = false) String firstName, @RequestParam(required = false) String lastName, Locale locale) {
return teacherService.getByFilter(new PageRequestParameters<>(new PaginationPage(page, number), new StudentTeacherFilter(firstName, lastName)), locale).map(this::convertToDto);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Results getResultsPage(FilterSpecifier.ListBy listBy, int page) throws SearchServiceException;",
"List<Product>findAllBy(Pageable pageable);",
"List<T> findPage(int pageNumber);",
"List<ProductView> getAllByPage(PageableAndSortable pageableAndSortable) throws ProductException;",
"List<E> page(Page page, Lo... | [
"0.71280843",
"0.70711976",
"0.699261",
"0.6905738",
"0.6837178",
"0.6824905",
"0.68131256",
"0.68122363",
"0.67074025",
"0.66833574",
"0.6683197",
"0.6673531",
"0.66525006",
"0.6636145",
"0.65953577",
"0.65860564",
"0.65736175",
"0.65734935",
"0.6569562",
"0.6538479",
"0.652... | 0.0 | -1 |
method return teacher by id | @GetMapping("/{id}")
public TeacherDTO getById(@PathVariable Long id, Locale locale) {
return convertToDto(teacherService.getById(id, locale));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static Teachers getTeacher(int teacher_id) {\n\n Teachers teacher = null;\n\n String sql = \"SELECT * FROM teachers WHERE teacher_id = \" + teacher_id;\n\n try (Connection connection = Database.getConnection();\n Statement statement = connection.createStatement();\n ... | [
"0.8228738",
"0.8215154",
"0.8172435",
"0.8102885",
"0.7994623",
"0.7645469",
"0.7571009",
"0.7564184",
"0.75562775",
"0.75418466",
"0.7508473",
"0.75067604",
"0.75057375",
"0.7469534",
"0.7378125",
"0.7378125",
"0.73419464",
"0.72934186",
"0.72602713",
"0.7237645",
"0.703599... | 0.6608641 | 29 |
method return all teachers by group id | @GetMapping("/getByGroupId/{id}")
public List<TeacherDTO> getTeachersOfGroupById(@PathVariable Long id, Locale locale) {
return teacherService.getTeachersOfGroupById(id, locale).stream()
.map(this::convertToDto)
.collect(Collectors.toList());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Produces(MediaType.APPLICATION_JSON)\n @Override\n public List<Teacher> getAllTeachers() {\n List<Map<String, Object>> teachersIds = getJdbcTemplate().queryForList(sqlGetAllTeachersIds);\n if (teachersIds.size() == 0) {\n return null;\n }\n // find list of lessons by I... | [
"0.6555924",
"0.63912225",
"0.6337535",
"0.6322257",
"0.6321173",
"0.6288528",
"0.62658596",
"0.6056561",
"0.6041917",
"0.60362643",
"0.60024315",
"0.59549433",
"0.5930981",
"0.5858546",
"0.5840528",
"0.58387834",
"0.5830117",
"0.57780665",
"0.57718724",
"0.57607365",
"0.5756... | 0.67832756 | 0 |
update teacher by id | @PutMapping("/{id}")
public TeacherDTO updateById(@RequestBody TeacherDTO teacherDTO, @PathVariable Long id, Locale locale) {
Teacher teacher = teacherService.updateById(convertToEntity(teacherDTO), id, locale);
return convertToDto(teacher);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void update(int id, int teacherid, int noteid );",
"@Override\n\tpublic void update(Teacher teacher) {\n\t\tdao.update(teacher);\n\t}",
"@Override\n\tpublic void update(Teacher teacher) {\n\t\tteacherDao.update(teacher);\n\t}",
"int updateByPrimaryKey(Teacher record);",
"public void update(Teacher o) throw... | [
"0.8013928",
"0.77629346",
"0.7743405",
"0.765729",
"0.74933726",
"0.7399734",
"0.7354573",
"0.72274363",
"0.72235715",
"0.71800476",
"0.7145709",
"0.7031425",
"0.70188355",
"0.70188355",
"0.69499135",
"0.6839242",
"0.6837074",
"0.6715877",
"0.65302086",
"0.65247333",
"0.6504... | 0.7182711 | 9 |
method delete teacher by id | @DeleteMapping("/{id}")
public void deleteById(@PathVariable Long id, Locale locale) {
teacherService.deleteById(id, locale);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void deleteTea(Teacher teacher) {\n\r\n\t}",
"@Produces(MediaType.APPLICATION_JSON)\n @Override\n public Boolean deleteTeacherById(int teacherId) {\n List<Lesson> lessonsAttachedToThisTeacher = lessonService.findAllLessonsByTeacher(teacherId).getBody();\n if (lessonsAtta... | [
"0.80912775",
"0.76120853",
"0.7527081",
"0.7465361",
"0.7112306",
"0.7015543",
"0.6998076",
"0.6918206",
"0.68443054",
"0.6797797",
"0.6766729",
"0.674829",
"0.672892",
"0.6678257",
"0.6588979",
"0.6586553",
"0.6586553",
"0.6586553",
"0.6586553",
"0.6586553",
"0.6574033",
... | 0.72591615 | 4 |
method save entities in database from excel file | @PostMapping("/upload")
public ValidationStatus addGroupsToTeacher(@RequestParam(value = "file") MultipartFile file, Locale locale) throws IOException {
return fileService.parse(locale, file.getInputStream(), file.getOriginalFilename().split("\\.")[1], teacherService::validate, teacherService::save);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Transactional(propagation=Propagation.NOT_SUPPORTED)\r\n\tpublic List<T> importSave(MultipartFile file, T entity) throws Exception{\r\n\t\t\r\n\t\tString originName = file.getOriginalFilename();\t\t\t\t\t\t\t// 取得原文件名\r\n\t\tString fileExt = originName.substring(originName.lastIndexOf(\".\") + 1); // 取得文件后缀\r\n\t... | [
"0.64480823",
"0.6446681",
"0.631084",
"0.6260228",
"0.5994516",
"0.59119904",
"0.58970106",
"0.5843126",
"0.5832677",
"0.5784971",
"0.5721135",
"0.5721135",
"0.5721135",
"0.5721135",
"0.5719796",
"0.5713331",
"0.5708585",
"0.5688029",
"0.56646526",
"0.5663522",
"0.56509054",... | 0.0 | -1 |
method return all sorted teachers using oracle package | @GetMapping("/sort-asc")
public List<TeacherDTO> getSortedTeachers() {
return teacherService.getSortedTeachers().stream()
.map(this::convertToDto)
.collect(Collectors.toList());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private ArrayList<Teacher> sortTeacherByPriorty(ArrayList<Teacher> teachers, ArrayList<Integer> preferedTeachers, int numSections) {\n ArrayList<Teacher> aux = new ArrayList<>();\r\n if (preferedTeachers.isEmpty()) {\r\n return aux;\r\n }\r\n\r\n for (int i = 0; i < numSectio... | [
"0.61441296",
"0.6055155",
"0.59686464",
"0.591254",
"0.58704126",
"0.581893",
"0.5798971",
"0.5760366",
"0.5699084",
"0.56615746",
"0.565213",
"0.5628237",
"0.5619795",
"0.5605186",
"0.55979925",
"0.5569948",
"0.55541575",
"0.552829",
"0.5523416",
"0.55217725",
"0.55195075",... | 0.6475666 | 0 |
method return all sorted revert teachers using oracle package | @GetMapping("/sort-desc")
public List<TeacherDTO> getSortedRevertTeachers() {
return teacherService.getSortedRevertTeachers().stream()
.map(this::convertToDto)
.collect(Collectors.toList());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"LiveData<List<Recommendation>> getAllRecsSortRefreshed() {\n allRecs = recommendationRepository.getAllRecsSortRefreshed();\n return allRecs;\n }",
"List<StatementsWithSorting> selectAll();",
"private ArrayList<Teacher> sortTeacherByPriorty(ArrayList<Teacher> teachers, ArrayList<Integer> prefer... | [
"0.5569337",
"0.54326546",
"0.5369069",
"0.53171957",
"0.5306997",
"0.52942455",
"0.5291552",
"0.52805907",
"0.52732146",
"0.52446973",
"0.52133226",
"0.5207644",
"0.5188922",
"0.51743984",
"0.51677",
"0.51388574",
"0.51361495",
"0.5108931",
"0.50932705",
"0.50930566",
"0.509... | 0.6559899 | 0 |
added by Jacob Davidson | public void setTrajectoryID(int trajectoryid) {
this.trajectoryid = trajectoryid;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void func_104112_b() {\n \n }",
"protected boolean func_70814_o() { return true; }",
"public void method_4270() {}",
"private static void cajas() {\n\t\t\n\t}",
"public final void mo51373a() {\n }",
"private void kk12() {\n\n\t}",
"private void strin() {\n\n\t}",
... | [
"0.562478",
"0.5473972",
"0.54549044",
"0.54067904",
"0.539698",
"0.5360954",
"0.5356728",
"0.5339144",
"0.53388065",
"0.53280026",
"0.531321",
"0.5308296",
"0.5287214",
"0.5282353",
"0.52499604",
"0.52446395",
"0.5234513",
"0.5234513",
"0.5227142",
"0.5198145",
"0.5183228",
... | 0.0 | -1 |
Returns the type corresponding to a name, but never throws an exception. Returns NotCarrying if a valid value could not be found. | public static Activity safeValueOf(String name) {
try {
return valueOf(name);
}
catch (Exception ex) {
return NotCarrying;
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Type<?> get(String name);",
"public static Type valueOfIgnoreCase(String name) throws IllegalArgumentException {\n for(Type type: Type.values()) {\n if(type.getName().equalsIgnoreCase(name)) return type;\n }\n\n throw new IllegalArgumentException(String.format(\"Type object with t... | [
"0.6562009",
"0.6554395",
"0.64689434",
"0.6467875",
"0.6084218",
"0.59734744",
"0.5955249",
"0.5944994",
"0.59121937",
"0.58946896",
"0.58204937",
"0.58104104",
"0.5808518",
"0.5800091",
"0.5797486",
"0.5796104",
"0.5749199",
"0.5741798",
"0.56656414",
"0.56324977",
"0.55686... | 0.5508958 | 27 |
Constructs a copy of another point | public Point(Point other) {
super(other);
this.x = other.x;
this.y = other.y;
this.activity = other.activity;
this.frame = other.frame;
this.trajectoryid = other.trajectoryid;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Point clone ();",
"public SoPickedPoint \ncopy() \n//\n////////////////////////////////////////////////////////////////////////\n{\n SoPickedPoint newCopy = new SoPickedPoint(this);\n return newCopy;\n}",
"public Object clone() {\n return new PointImpl( this );\n }",
"@Override\n public Ge... | [
"0.8245929",
"0.7190616",
"0.7178689",
"0.7164989",
"0.71556073",
"0.7112724",
"0.7090368",
"0.69846743",
"0.6961145",
"0.6919659",
"0.68910646",
"0.6830259",
"0.6684309",
"0.6683675",
"0.66660017",
"0.6662406",
"0.6554786",
"0.654411",
"0.64904976",
"0.6356418",
"0.6285728",... | 0.7258417 | 1 |
added by Jacob Davidson | public int getTrajectoryID() {
return trajectoryid;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void func_104112_b() {\n \n }",
"protected boolean func_70814_o() { return true; }",
"public void method_4270() {}",
"private static void cajas() {\n\t\t\n\t}",
"public final void mo51373a() {\n }",
"private void kk12() {\n\n\t}",
"private void strin() {\n\n\t}",
... | [
"0.562478",
"0.5473972",
"0.54549044",
"0.54067904",
"0.539698",
"0.5360954",
"0.5356728",
"0.5339144",
"0.53388065",
"0.53280026",
"0.531321",
"0.5308296",
"0.5287214",
"0.5282353",
"0.52499604",
"0.52446395",
"0.5234513",
"0.5234513",
"0.5227142",
"0.5198145",
"0.5183228",
... | 0.0 | -1 |
Returns true if the attribute "radioValue" is set. | public final boolean isRadioValueSetted() {
return engine.isPropertySetted(Properties.RADIO_VALUE);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public boolean hasValue() throws SdpParseException {\n\t\tNameValue nameValue = getAttribute();\n\t\tif (nameValue == null)\n\t\t\treturn false;\n\t\telse {\n\t\t\tObject value = nameValue.getValue();\n\t\t\tif (value == null)\n\t\t\t\treturn false;\n\t\t\telse\n\t\t\t\treturn true;\n\t\t}\n\t}",
"public boolean... | [
"0.6666272",
"0.64535606",
"0.6248936",
"0.6231041",
"0.61704534",
"0.61623174",
"0.6152496",
"0.6150921",
"0.6110908",
"0.61043286",
"0.6020867",
"0.6002174",
"0.5997164",
"0.5831065",
"0.5829528",
"0.5829528",
"0.58262473",
"0.5823484",
"0.57973135",
"0.5746798",
"0.5737554... | 0.8030418 | 0 |
Returns true if the attribute "groupName" is set. | public final boolean isGroupNameSetted() {
return engine.isPropertySetted(Properties.GROUP_NAME);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public boolean isSetGroup() {\n return this.group != null;\n }",
"public boolean groupSpecified() {\n return group != null && !group.isEmpty();\n }",
"public boolean inGroup(String groupName) {\r\n return true;\r\n }",
"public boolean isSetName()\r\n {\r\n ... | [
"0.7043588",
"0.70147026",
"0.69311655",
"0.6830658",
"0.68109465",
"0.6685956",
"0.6592286",
"0.65636265",
"0.6464959",
"0.6464959",
"0.6464959",
"0.6464959",
"0.64549726",
"0.6445037",
"0.64427745",
"0.6431303",
"0.64301807",
"0.64241266",
"0.6370602",
"0.63469213",
"0.6332... | 0.78704894 | 0 |
TODO Autogenerated method stub | public static void main(String[] args) {
Mammal mammalFirst = new Mammal();
int mammalFirstEnergy = mammalFirst.displayEnergy();
System.out.println("Mammal Energy Level is: " + mammalFirstEnergy);
Gorilla gorillaFirst = new Gorilla();
String printCurrentGorillaEnergyLevel = "Gorilla Energy Level is: " + gorillaFirst.displayEnergy();
int gorrillaFirstEnergy = gorillaFirst.displayEnergy();
System.out.println("Gorilla Energy Level is: " + gorrillaFirstEnergy);
//throw 3
String gorillaThrow1 = gorillaFirst.throwSomething();
System.out.println(gorillaThrow1);
System.out.println(printCurrentGorillaEnergyLevel);
String gorillaThrow2 = gorillaFirst.throwSomething();
System.out.println(gorillaThrow2);
System.out.println(printCurrentGorillaEnergyLevel);
String gorillaThrow3 = gorillaFirst.throwSomething();
System.out.println(gorillaThrow3);
System.out.println(printCurrentGorillaEnergyLevel);
//eat 2
String gorillaEatBan1 = gorillaFirst.eatBananas();
System.out.println(gorillaEatBan1);
System.out.println(printCurrentGorillaEnergyLevel);
String gorillaEatBan2 = gorillaFirst.eatBananas();
System.out.println(gorillaEatBan2);
System.out.println(printCurrentGorillaEnergyLevel);
//climb 1
String gorillaClimb1 = gorillaFirst.climb();
System.out.println(gorillaClimb1);
System.out.println(printCurrentGorillaEnergyLevel);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.66708666",
"0.65675074",
"0.65229905",
"0.6481001",
"0.64770633",
"0.64584893",
"0.6413091",
"0.63764185",
"0.6275735",
"0.62541914",
"0.6236919",
"0.6223816",
"0.62017626",
"0.61944294",
"0.61944294",
"0.61920846",
"0.61867654",
"0.6173323",
"0.61328775",
"0.61276996",
"0... | 0.0 | -1 |
some double adds that should not matter | public static void enter_values(TagBasedEncoder<?> encoder) {
encoder.addEntryT(bool_test_tag, bool_test_value);
encoder.addEntryT("confuse???123123", 1234123+"WeirdTag ValueSwear");
encoder.addEntryT(str_test_tag, str_test_value);
encoder.addEntryT("confuse???1231235", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT("confuse???1231235", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT(int_test_tag, int_test_value);
encoder.addEntryT("WeirdTag confuse", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT("confuse???", 1234123+"WeirdTagVa lueSwear");
encoder.addEntryT(weird_long_tag, weird_long_value);
encoder.addEntryT(empty_tag_test_tag, empty_tag_test_value);
encoder.addEntryT(empty_val_test_tag, empty_val_test_value);
encoder.addEntryT("confuse???1231235", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT(empty_strarr_test_tag, empty_strarr_test_value); //empty is not written into the system.
encoder.addEntryT(strarr_test_tag, strarr_test_value);
encoder.addEntryT(empty_intarr_test_tag, empty_intarr_test_value); //empty is not written into the system.
encoder.addEntryT(intarr_test_tag, intarr_test_value);
encoder.addEntryT("confuse???1231235", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT(strarr2d_test_tag, strarr2d_test_value);
encoder.addEntryT("confuse???1231235", 1234123+"WeirdTa gValueSwear");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n\tpublic double add(double in1, double in2) {\n\t\treturn 0;\n\t}",
"public void add()\r\n {\r\n resultDoubles = Operations.addition(leftOperand, rightOperand);\r\n resultResetHelper();\r\n }",
"@Override\n\tpublic double add(double a, double b) {\n\t\treturn (a+b);\n\t}",
"Double add(Doub... | [
"0.7498091",
"0.7243579",
"0.7154469",
"0.71069074",
"0.694341",
"0.6879942",
"0.674453",
"0.6598903",
"0.6566361",
"0.6556864",
"0.64059687",
"0.64015454",
"0.6376668",
"0.63438666",
"0.63360614",
"0.6283175",
"0.62240297",
"0.61955094",
"0.6194916",
"0.6188527",
"0.61861956... | 0.0 | -1 |
Tests for most(except infinite variations on arrays) available, supported data types whether or not it can correctly recreate the stored object. This functionality is required by the serializer | public static void basic_typed_system_test(TagBasedEncoder<?> tbe) {
Object orig_1 = "whatup";
Object orig_2 = false;
Object orig_3 = (byte) 123;
Object orig_4 = 65432;
Object orig_5 = 45645674655L;
Object orig_6 = true;
Object orig_7 = (byte)-23;
Object orig_8 = -6123123;
Object orig_9 = -32472532423245L;
Object orig_10 = new String[] {"123123141", "234234234", "gsdkjlhgsjdfsjlg", "test"};
Object orig_11 = new boolean[]{false, true, true, false};
Object orig_12 = new byte[]{-12, 13, 15, 93, -80};
Object orig_13 = new int[]{121321, -123123, 123123, 123123, -14123, 876574};
Object orig_14 = new long[]{-32472213123423245L, -32472212423245L, -32472532423242L};
Object orig_15 = new String[][]{{"test", "test", "test"}, {"1", "2", "3"}};
Object orig_16 = new LIbae();
Object orig_17 = new LIse("hallo", "dies", "ist", "ein", "test");
tbe.addEntryT("#####1", orig_1);
tbe.addEntryT("#####2", orig_2);
tbe.addEntryT("#####3", orig_3);
tbe.addEntryT("#####4", orig_4);
tbe.addEntryT("#####5", orig_5);
tbe.addEntryT("#####6", orig_6);
tbe.addEntryT("#####7", orig_7);
tbe.addEntryT("#####8", orig_8);
tbe.addEntryT("#####9", orig_9);
tbe.addEntryT("#####10", orig_10);
tbe.addEntryT("#####11", orig_11);
tbe.addEntryT("#####12", orig_12);
tbe.addEntryT("#####13", orig_13);
tbe.addEntryT("#####14", orig_14);
tbe.addEntryT("#####15", orig_15);
tbe.addEntryT("#####16", orig_16);
tbe.addEntryT("#####17", orig_17);
String result_1 = tbe.getEntryT("#####1", String.class);
Boolean result_2 = tbe.getEntryT("#####2", Boolean.class);
Byte result_3 = tbe.getEntryT("#####3", Byte.class);
Integer result_4 = tbe.getEntryT("#####4", Integer.class);
Long result_5 = tbe.getEntryT("#####5", Long.class);
boolean result_6 = tbe.getEntryT("#####6", boolean.class);
byte result_7 = tbe.getEntryT("#####7", byte.class);
int result_8 = tbe.getEntryT("#####8", int.class);
long result_9 = tbe.getEntryT("#####9", long.class);
String[] result_10 = tbe.getEntryT("#####10", String[].class);
boolean[] result_11 = tbe.getEntryT("#####11", boolean[].class);
byte[] result_12 = tbe.getEntryT("#####12", byte[].class);
int[] result_13 = tbe.getEntryT("#####13", int[].class);
long[] result_14 = tbe.getEntryT("#####14", long[].class);
String[][] result_15 = tbe.getEntryT("#####15", String[][].class);
LIbae result_16 = tbe.getEntryT("#####16", LIbae.class);
LIse result_17 = tbe.getEntryT("#####17", LIse.class);
assertEquals(orig_1, result_1);
assertEquals(orig_2, result_2);
assertEquals(orig_3, result_3);
assertEquals(orig_4, result_4);
assertEquals(orig_5, result_5);
assertEquals(orig_6, result_6);
assertEquals(orig_7, result_7);
assertEquals(orig_8, result_8);
assertEquals(orig_9, result_9);
assertArrayEquals((String[])orig_10, result_10);
assertArrayEquals((boolean[]) orig_11, result_11);
assertArrayEquals((byte[]) orig_12, result_12);
assertArrayEquals((int[]) orig_13, result_13);
assertArrayEquals((long[]) orig_14, result_14);
assertArrayEquals((String[][]) orig_15, result_15);
assertEquals(orig_16, result_16);
assertEquals(orig_17, result_17);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public boolean isArray() {\n return false;\n }",
"@Override\r\n public boolean isArray() throws Exception\r\n {\n return false;\r\n }",
"public static boolean isArray_dataType() {\n return false;\n }",
"public void fixmetestPositiveArray() {\n\n fail(\"Array ... | [
"0.61779934",
"0.6124134",
"0.6109963",
"0.59630734",
"0.5833123",
"0.5764128",
"0.5726039",
"0.56614447",
"0.5660996",
"0.5654333",
"0.5576033",
"0.55685955",
"0.55659246",
"0.5562296",
"0.5562296",
"0.55170137",
"0.55043423",
"0.5495773",
"0.5493811",
"0.54799765",
"0.54793... | 0.0 | -1 |
some double adds that should not matter | public static void enter_values(TupleTagBasedEncoder<?> encoder) {
encoder.addEntryT(super_tag_1, bool_test_tag, bool_test_value);
encoder.addEntryT(super_tag_1,"confuse???123123", 1234123+"WeirdTag ValueSwear");
encoder.addEntryT(super_tag_2, str_test_tag, str_test_value);
encoder.addEntryT(super_tag_1, "confuse???1231235", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT(super_tag_1, "confuse???1231235", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT(super_tag_1, int_test_tag, int_test_value);
encoder.addEntryT(super_tag_4, "WeirdTag confuse", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT(super_tag_2, "confuse???", 1234123+"WeirdTagVa lueSwear");
encoder.addEntryT(super_tag_2, weird_long_tag, weird_long_value);
encoder.addEntryT(super_tag_4, empty_tag_test_tag, empty_tag_test_value);
encoder.addEntryT(super_tag_2, empty_val_test_tag, empty_val_test_value);
encoder.addEntryT(super_tag_2, "confuse???1231235", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT(super_tag_4, empty_strarr_test_tag, empty_strarr_test_value); //empty is not written into the system.
encoder.addEntryT(super_tag_2, strarr_test_tag, strarr_test_value);
encoder.addEntryT(super_tag_2, empty_intarr_test_tag, empty_intarr_test_value); //empty is not written into the system.
encoder.addEntryT(super_tag_4, intarr_test_tag, intarr_test_value);
encoder.addEntryT(super_tag_3, "confuse???1231235", 1234123+"WeirdTa gValueSwear");
encoder.addEntryT(super_tag_2, strarr2d_test_tag, strarr2d_test_value);
encoder.addEntryT(super_tag_4, "confuse???1231235", 1234123+"WeirdTa gValueSwear");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n\tpublic double add(double in1, double in2) {\n\t\treturn 0;\n\t}",
"public void add()\r\n {\r\n resultDoubles = Operations.addition(leftOperand, rightOperand);\r\n resultResetHelper();\r\n }",
"@Override\n\tpublic double add(double a, double b) {\n\t\treturn (a+b);\n\t}",
"Double add(Doub... | [
"0.7498091",
"0.7243579",
"0.7154469",
"0.71069074",
"0.694341",
"0.6879942",
"0.674453",
"0.6598903",
"0.6566361",
"0.6556864",
"0.64059687",
"0.64015454",
"0.6376668",
"0.63438666",
"0.63360614",
"0.6283175",
"0.62240297",
"0.61955094",
"0.6194916",
"0.6188527",
"0.61861956... | 0.0 | -1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.