query stringlengths 8 1.54M | document stringlengths 9 312k | negatives listlengths 19 20 | metadata dict |
|---|---|---|---|
create index for table | public void createIndex(String tableName, String columnName)
throws Exception {
DBCollection dbCollection = db.getCollection(tableName);
DBObject indexData = new BasicDBObject(columnName, 1);
dbCollection.createIndex(indexData);
} | [
"@Override\n\tpublic void createIndex(String table, String database, String... fieldNames) {\n\t\t\n\t}",
"public void createIndex(String column, String table)\n\t{\n\t\tif(this.db == null) return;\n\t\t\n\t\tthis.execute(\"CREATE INDEX i_\"+table+\"_\"+column+\" ON \"+table+\" (`\"+column+\"`)\");\t\t\t\t\n\t}",... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by MyBatis Generator. This method returns the value of the database column power_cdmeterdata_total_s.equi_status | public Integer getEquiStatus() {
return equiStatus;
} | [
"public ConditionStatus getStatus();",
"public Integer getStatus(){\n try{\n return this.getInt(\"status\");\n }catch(Exception e){}\n return null;\n }",
"public Float getStatus() {\n return status;\n }",
"public Integer getEmployeestatus() {\n return employ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__ActiveFilter__Group__1" $ANTLR start "rule__ActiveFilter__Group__1__Impl" InternalQLParser.g:4311:1: rule__ActiveFilter__Group__1__Impl : ( Active ) ; | public final void rule__ActiveFilter__Group__1__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalQLParser.g:4315:1: ( ( Active ) )
// InternalQLParser.g:4316:1: ( Active )
{
// InternalQLParser.g:4316:1: (... | [
"public final void rule__FilterSpec__Group__1() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.xtext.firewall.iptables.ui/src-gen/org/xtext/example/iptables/ui/contentassist/antlr/internal/InternalIptables.g:1655:1: ( rule__FilterSpe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Moves the block down continually as the game is being played Drop rate depends on difficulty | public void step()
{
if(difficulty==0)
{
numSteps++;
}
if(difficulty==1)
{
numSteps+=2;
}
if(difficulty==2)
{
numSteps+=5;
//numSteps+=8;
}
if(currentBlock==null)
{
currentBlock=getNextBlock();
nextBlock=inactive.get(0);
setMessage("Press Start to begin\nScore: " + ... | [
"void blocksup()\n {\n add1=del1;\n del1=del1-bspeed;\n if(change==1)\n {\n change=2;\n }\n else\n {\n change=1;\n }\n }",
"public void moveArm_blockLevelDown(){\n if (currentLevel > 1) {\n turnArmBrakeModeOn(); ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__Declaraciones__DAssignment_7" $ANTLR start "rule__Instrucciones__IAssignment_1_0_2" InternalLinit.g:6566:1: rule__Instrucciones__IAssignment_1_0_2 : ( ruleinstrucciones ) ; | public final void rule__Instrucciones__IAssignment_1_0_2() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalLinit.g:6570:1: ( ( ruleinstrucciones ) )
// InternalLinit.g:6571:2: ( ruleinstrucciones )
{
// Internal... | [
"public interface AnalyseurSyntaxiqueConstants {\n\n /** End of File. */\n int EOF = 0;\n /** RegularExpression Id. */\n int MULTI_LINE_COMMENT = 7;\n /** RegularExpression Id. */\n int BOOLEAN = 9;\n /** RegularExpression Id. */\n int DO = 10;\n /** RegularExpression Id. */\n int ELSE = 11;\n /** Regula... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public void propagateOrOptMove2(Point x1, Point x2, Point y) {
TreeSet<Integer>st = new TreeSet<Integer>();
st.add(XR.oldRoute(x1));
st.add(XR.oldRoute(y));
for(Integer k : st)
propagate(k);
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
paintComponent method, this method does the transformation of the images it depends if the right or left side is clicked | @Override
public void paintComponent(Graphics g){
super.paintComponent(g);
g.setColor(Color.black);
g.fillRect(0,0,getWidth(),getHeight());
if(frameNum==1){
g.drawImage(pictures.get(0),0,0,this);
g.drawImage(pictures.get(1),634,0,this);
}
... | [
"@Override\n\t\t\t\tpublic void mouseClicked(MouseEvent e) {\n\t\t\t\t\t\n\t\t\t\t\t if(e.getButton() == MouseEvent.BUTTON1) {\n\t\t\t\t //setText(\"Left Click!\");\n\t\t\t\t\t\t //move the figure shape to left by one square\n\t\t left=true;\n\t\t do_initialize=fa... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Phrases are lower cased, but these bad words must have their case restored. | public static String restoreCaseOnAnyBadWords(String phrase) {
return phrase.replace("mtitle", "mTitle").replace("mmessage", "mMessage");
} | [
"boolean getForceLowercaseEnglish();",
"protected void validatePhraseIgnored(java.lang.String[] param){\n \n }",
"private static String standardize(String unstandardized) {\n\t\tString standard = unstandardized.toLowerCase().replace(\" \", \"\");\n\t\tret... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
auths not ready at this time The purpose of this method is to search a value in PruebaProjNoun table from database based on given inputs | @ApiOperation(value = "/search_PruebaProjNoun", httpMethod = "GET",notes = "searches a noun of PruebaProjNoun",response = PruebaProjNoun.class)
@ApiResponses(value = {
@ApiResponse(code = 200, message = PruebaProjSwaggerUIConstants.SUCCESS),
@ApiResponse(code = 404, message = PruebaProjSwaggerUIConstants.NOT_FO... | [
"public void searchProcedure(String proId) {\n try {\n Connection conn = DriverManager.getConnection(\"jdbc:ucanaccess://E:\\\\Databasejava\\\\Stu.accdb\");\n Statement s = conn.createStatement();\n String statement = \"SELECT * FROM Procedure where Pro_ID=\" + proId;\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public void delete(Tick tick) {
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Required specifies hard node constraints that must be met. | @JsonProperty("required")
public IoK8sApiCoreV1NodeSelector getRequired() {
return required;
} | [
"public void setRequired(final boolean required) {\n this._required = required;\n }",
"public void setRequired(boolean b)\n {\n required = b;\n }",
"public final void mREQUIRED() throws RecognitionException {\n try {\n int _type = REQUIRED;\n int _channel = DEFAULT_... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
extra contains extra attributes of the user that created the CertificateSigningRequest. Populated by the API server on creation and immutable. +optional map<string, .k8s.io.api.certificates.v1.ExtraValue> extra = 6; | int getExtraCount(); | [
"Map<String, Object> extra();",
"public RequestParameter(IParameter<String, String> extra) {\n this.keyValues = new LinkedHashMap<>();\n putAll(extra.getAll());\n }",
"Map<String,Object> getExtraAttrs();",
"com.google.protobuf.ByteString getExtraBytes();",
"@Field(8) \n\tpublic libusb_endpo... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
nothing to be done for now. | @Override
public void preInstallHook() {
} | [
"@Override\n }",
"@Override\n public void extornar() {\n \n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"private static void EX5() {\n\t\t\r\n\t}",
"protected void mo4791d() {\n }",
"@Override\n\t\tprotected void swop() {\n\n\t\t}",
"protected void... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__Funciones__NombreAssignment_0_1" $ANTLR start "rule__Funciones__OperadoresAssignment_0_3_0" ../vary.pseudocodigo.dsl.cpp.ui/srcgen/vary/pseudocodigo/dsl/cpp/ui/contentassist/antlr/internal/InternalVaryGrammar.g:15556:1: rule__Funciones__OperadoresAssignment_0_3_0 : ( ruleoperacion ) ; | public final void rule__Funciones__OperadoresAssignment_0_3_0() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../vary.pseudocodigo.dsl.cpp.ui/src-gen/vary/pseudocodigo/dsl/cpp/ui/contentassist/antlr/internal/InternalVaryGrammar.g:15560:1: ( ( ruleope... | [
"public final void rule__Objeto__NombreAssignment_1() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../co.edu.uniandes.miso4202.vehicletax.ui/src-gen/co/edu/uniandes/miso4202/ehicletax/ui/contentassist/antlr/internal/InternalVtdsl.g:4339:1... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
repeated .datayes.mdl.mdl_szl2_pbmsg.StockInfo.SecurityAltIDsItem SecurityAltIDs = 7; | public datayes.mdl.mdl_szl2_pbmsg.MDLSZL2Msg.StockInfo.SecurityAltIDsItemOrBuilder getSecurityAltIDsOrBuilder(
int index) {
return securityAltIDs_.get(index);
} | [
"public static interface Contants$Message$SecurityLevel\n{\n\n\tpublic static final int DATA_CHECK_CRC = 2;\n\tpublic static final int DATA_CHECK_MAC = 1;\n\tpublic static final int DATA_ENCRYPT_3DES = 1;\n\tpublic static final int DATA_NO_CHECK = 0;\n\tpublic static final int DATA_NO_ENCRYPT = 0;\n}",
"public St... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Validates if the message corresponds to given XSDs. | public MessageValidator validate(String schemaPath, String... schemaPaths) throws IOException {
Resource[] schemas = new Resource[schemaPaths.length];
for (int i = 0; i < schemas.length; i++) {
schemas[i] = resourceLoader.getResource(schemaPaths[i]);
}
return validate(resourceLoader.getResource(schemaPath), ... | [
"public boolean validateByXSD(String xsdFilePath) {\n //create xml default error handler\n XMLErrorHandler errorHandler = new XMLErrorHandler(); \n //get SAX parser factory\n SAXParserFactory factory = SAXParserFactory.newInstance(); \n factory.setValidating(tr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
NOTE: The direction of this is used for map rotation only, not location layer rotation | private double getDirectionForUserLocationUpdate() {
CameraState currentCamera = mMapView.getMapboxMap().getCameraState();
double direction = currentCamera.getBearing();
int userTrackingMode = mUserLocation.getTrackingMode();
if (userTrackingMode == UserTrackingMode.FollowWithHeading |... | [
"public void updateDirection() {\n\t\trotation %= 360;\n\t\tif (rotation < 0) {\n\t\t\trotation = (360+rotation);\n\t\t}\n\n//\t\trotation = Math.abs(360-rotation);\n\t}",
"@Override\n\tpublic void rotate() {\n\t\tif(pos == RightAngle.leftTop){\n\t\t\tpos = RightAngle.rightTop;\n\t\t}else if(pos == RightAngle.rig... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Datei einlesen Eingabestroeme oeffnen | private static void umlauteFiltern(String htmlOriginal, String htmlGeand) throws IOException {
FileInputStream fiStream = new FileInputStream(htmlOriginal);
BufferedReader br = new BufferedReader(new InputStreamReader(fiStream, "ISO8859_1")); //Zeichencodierung, damit die Umlaute vernünftig eingelesen w... | [
"public Date getNgayHetHieuLuc();",
"Date proveer();",
"private Fecha()\n\t{\n\t\t\n\t\tDateFormat dateFormat = new SimpleDateFormat(\"yyyy/MM/dd HH:mm:ss\");\n\t Date date = new Date();\n\t\tfecha=dateFormat.format(date);\n\t\tDateFormat dateFormat2 = new SimpleDateFormat(\"yyyy/MM/dd\");\n\t\tDate date2 = ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public void onClick(View v) {
if(v.getId()==R.id.btnBuscarProducto){
Intent buscarProductoIntent = new Intent(AgregarProductoActivity.this, BuscarProductoActivity.class);
//agregarProductoIntent.putExtra("codigoProducto", det.getIdPedido());
startActivityForResult(buscarProductoIntent,BUSCAR_PRODU... | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Instantiate the object from a map. Each entry in the map reflects to a field. | public BoxEventCollection(Map<String, Object> map) {
super(map);
} | [
"public ISType instantiate(Map<PolyParaType, ISType> map);",
"A_Map fieldMap ();",
"public AbstractDataType(final Map<String, String> map) {\n\t\tthis.fieldsMap = map;\n\t}",
"public static MapFeature create(Map<String, Object> map) {\n return new MapFeature(null, map);\n }",
"private void createM... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ rand.nextInt(k) will always generates a number between 0 ~ (k1). Access the documents with the masks can help us split the whole whole corpus into k folders. The function is used in cross validation. | public void shuffle(int k) {
Random rand = new Random();
for(int i=0; i< m_mask.length; i++) {
this.m_mask[i] = rand.nextInt(k);
}
} | [
"public void generateRandomFile(){\r\n\t\tint nodeCount = 124;\r\n\t\tboolean[][]result = new boolean[nodeCount][nodeCount];\r\n\r\n\t\t//\tThe zero layer\r\n\t\tfor(int i = 1;i <= 20;i++){\r\n\t\t\tresult[0][i] = true;\r\n\t\t}\r\n\t\t\r\n\t\t//\tThe first layer\r\n\t\tfor(int i = 1;i <= 20;i++){\r\n\t\t\tresult[i... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Inflate the menu; this adds items to the action bar if it is present. | @Override
public boolean onCreateOptionsMenu(Menu menu) {
getMenuInflater().inflate(R.menu.menu_main, menu);
return true;
} | [
"@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflator = getMenuInflater();\n\t\tinflator.inflate(R.menu.activity_action_bar, menu);\n\t\treturn super.onCreateOptionsMenu(menu);\n\t}",
"@Override\r\n public boolean onCreateOptionsMenu( android.view.Menu menu)\r\n {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Fires the new Connection state to all registered listeners. | private void fireConnectionStateChanged(ILoginStateListener.ConnectionState state) {
if (lsll.size() > 0) {
// we have to copy our current listeners cause e.g. XmppFileTransferMethod may
// registrate on our listener just as we are spreading the event...
for (ILoginStateListener lsl : new ArrayList<ILoginSta... | [
"protected void connect() {\n for (ConnectionListener listener : listeners) {\n listener.onConnect(this);\n }\n connected = true;\n }",
"public synchronized void newClientConnection()\n\t{\n\t\tfor (JPPFDriverListener listener: eventListeners) listener.newClientConnection();\n\t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
repeated string addr_list = 1; | public com.google.protobuf.ByteString
getAddrListBytes(int index) {
return addrList_.getByteString(index);
} | [
"public java.util.List<java.net.InetAddress> resolveInetAddresses(java.lang.String r3) {\n /*\n r2 = this;\n boolean r0 = com.bytedance.common.utility.C6319n.m19593a(r3)\n r1 = 0\n if (r0 != 0) goto L_0x003e\n boolean r0 = r2.mIsMainProcess\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the layer located at the given index. | ILayer getLayer(int i); | [
"public Layer getLayer(int index)\n \t{\n \t\treturn layers.get(index);\n \t}",
"fzdeepnet.Setting.Layer getLayer(int index);",
"final JXLayer<JComponent> getLayerAt(int index) {\n return components.get(index);\n }",
"IImage getLayer(int index) throws IllegalArgumentException;",
"public fzdeepnet.... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Called when the user clicks the Exit button | public void StartNewGame(View view) {
Intent intent = new Intent(this, GamePlayActivity.class);
startActivity(intent);
} | [
"public void onQuitButton() {\n Platform.exit();\n }",
"private void btnExit_clic() {\r\n\t\tSystem.exit(0);\r\n\t}",
"private void exitButtonActionPerformed(java.awt.event.ActionEvent evt) { \n System.exit(0);\n }",
"void onExit();",
"public void e... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Find the _Fields constant that matches fieldId, or null if its not found. | public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 0: // SUCCESS
return SUCCESS;
case 1: // ERR
return ERR;
default:
return null;
}
} | [
"@org.apache.thrift.annotation.Nullable\n public static _Fields findByThriftId(int fieldId) {\n switch(fieldId) {\n case 1: // HR_ID\n return HR_ID;\n case 2: // COMPANY_ID\n return COMPANY_ID;\n case 3: // COMPANY_TAG_IDS\n return COMPANY_TAG_... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return the size of your dataset (invoked by the layout manager) | @Override
public int getItemCount() {
return mDataset.size();
} | [
"public long getDataSize();",
"public int getDimensions() {\r\n return size;\r\n }",
"public int getDimensionSize() {\n return dimSize.length;\n }",
"public int getDimension()\r\n \t{\r\n \t\treturn size.numDimensions();\r\n \t}",
"public int getSize()\n {\n return getSizeX() * getSi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Detect reclaimed keys. It lods first results on the second call. It's heavy event. | public void computeRemoved(Set keys) {
if (logPerformance() == false) return;
if (System.currentTimeMillis() - removedInvocationTime > REMOVED_BATCH_INTERVAL) return;
removedInvocaionCounter++;
Iterator it = keys.iterator();
Set currentKeys = new HashSet(keys.size());
w... | [
"public void collectKey(Key keystepped){\r\n for (int i = 0; i < keysObtained.size(); i++){\r\n if (keysObtained.get(i).getName() == keystepped.getName()){\r\n keysObtained.remove(i);\r\n }\r\n }\r\n keysObtained.add(keystepped);\r\n }",
"private void s... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Created by bob on 1/19/18. | @MessageLogger(projectCode = CODE, length = 6)
public interface OpenApiMessages extends BasicLogger {
OpenApiMessages MESSAGES = Logger.getMessageLogger(OpenApiMessages.class, LoggingUtil.loggerCategory("openapi"));
int OFFSET = MessageOffsets.OPENAPI_OFFSET;
@LogMessage(level = Logger.Level.DEBUG)
@M... | [
"protected void method_5557() {}",
"private static void EX5() {\n\t\t\r\n\t}",
"@Override\n public void extornar() {\n \n }",
"protected void mo4791d() {\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"public void mo28221a() {\n }",
"public void mo1857d... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Apply appropriate styles based on the new changes. | private void do_update(int comment, int startLine, int numLines) throws BadLocationException {
String content = do_text();
int i, lineCount = do_getLineCount(content);
if (comment<0) comment = do_getStartingStyleOfLine(content, startLine);
// for each line, we apply the appropriate styl... | [
"void updateStyle() {\n\t\t// Invalidate all style\n\t\tactualStyle_ = new GStyle();\n\n\t\t// Update with owner style\n\t\tif (owner_ != null)\n\t\t\tactualStyle_.update(owner_.getActualStyle());\n\n\t\t// Update (and possibly override) with present style\n\t\tif (style_ != null)\n\t\t\tactualStyle_.update(style_)... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Compute RBF(radial basis function) kernel parameters for given distances. | private DenseMatrix rbfKernCompute(DenseMatrix distance, double kernInverseWidth, double kernVarianceRbf){
double wi2 = 0.5 * kernInverseWidth;
DenseMatrix K = (distance.scale(0-wi2).exp(Math.E)).scale(kernVarianceRbf);
return K;
} | [
"public RBFNetwork(T[] x, int[] y, Metric<T> distance, RadialBasisFunction[] rbf, T[] centers, boolean normalized) {\n if (x.length != y.length) {\n throw new IllegalArgumentException(String.format(\"The sizes of X and Y don't match: %d != %d\", x.length, y.length));\n }\n\n if (rbf.... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
end toString Return the year that the member joined the club Date created: Oct 2, 2015 | public int getYearJoined ( )
{
int year;
String [ ] fields = dateJoined.split ("/");
year = Integer.parseInt (fields [2]);
return year;
} | [
"public String getYear(){\n return Integer.toString(this.year);\n }",
"public final String year( ) {\n return this.year_;\n }",
"public java.lang.String getYear(){\r\n return localYear;\r\n }",
"public String getToYear() {\r\n retur... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Role management Adds a role definition. | protected void addRole(RoleDefinition roleDefinition) {
// ----- Preconditions -----
if (roleDefinition == null) {
throw new NullPointerException("roleDefinition");
}
// -------------------------
roles.put(roleDefinition.getName(), roleDefinition);
... | [
"private void addRole() {\n\t\tRole role = new Role(\"ROLE_USER\", \"user role\", privilegeService.findAllPrevileges());\n\t\troleService.findOrCreate(role);\n\t}",
"@Override\r\n\tpublic void addRole(Role role) {\n\t\troleMapper.addRole(role);\r\n\t}",
"public void addRole(Role role) {\n getRoles().add(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Simply selects the home view to render by returning its name. | @RequestMapping(value = "/home", method = RequestMethod.GET)
public String home(Locale locale, Model model) {
logger.info("Welcome home! The client locale is {}.", locale);
model.addAttribute("recentPostLists", homeService.getRecentPostList());
model.addAttribute("recommendPostLists", homeService.getRecommend... | [
"@GetMapping(Mappings.HOME)\n public String home(Model model) {\n return ViewNames.HOME;\n }",
"@RequestMapping(value = \"/common/home\")\n\tpublic String showHome() {\n\n\t\treturn \"home\";\n\t}",
"WelcomeView getWelcomeView();",
"public Page getHomePagePage() {\r\n\t\treturn getViewMeta().getH... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Given a string, if the first or last chars are 'x', return the string without those 'x' chars, and otherwise return the string unchanged. If the input is "xHix", then output is "Hi". | public static void main(String[] args)
{
Scanner sc = new Scanner(System.in);
System.out.print("Enter two string :");
String first = sc.next();
System.out.println(Removex(first));
sc.close();
} | [
"public String endX(String str) {\n\t if(str.length()<1) return str;\n\t if(str.charAt(0)=='x') return endX(str.substring(1,str.length())) + \"x\";\n\t return str.charAt(0) + endX(str.substring(1));\n\t}",
"public String withoutString(String base, String remove) {\n String ret = \"\";\n for(int i... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Construct a new JMXQuery | public JMXQuery(String mbean, String jmxCommand) {
this.beanName = mbean;
this.command = jmxCommand;
} | [
"public edu.uconn.psy.jtrace.parser.JtQueryType createJtQueryType()\n throws javax.xml.bind.JAXBException\n {\n return new edu.uconn.psy.jtrace.parser.impl.JtQueryTypeImpl();\n }",
"private Query<T> createQuery() {\n if (query == null) {\n query = (Query<T>) queryEngine.buildQuery... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Handle a mouse click (or a key event having the same effect as a mouse click) on a line. The 'One' in the method name stands for the selection Mode (SELECT_ONE). | private void clickLineOne(int line, boolean shift, boolean control, boolean repaint) {
if (! isSelected(line)) {
clickLineZeroOrOne( line, false, false, repaint );
}
} | [
"protected void mouseClicked(int rulerLine) {\n \t}",
"public void customClick(){\n if(hasClickFocus){\n if(hasPartners){\n hasClickFocus = true;\n updatePartners();\n }else{\n hasClickFocus = false;\n }\n\n }else{\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | private void bton2() {
bt2.setVisibility(View.INVISIBLE);
if(num%2==0){
bt2.setBackgroundResource(R.drawable.zero);
g2.setVisibility(View.VISIBLE);
g2.setBackgroundResource(R.drawable.zero);
num++;
b2=2;}
else
{
bt2.setBackgroundResource(R.drawable.crose);
g2.setVisibility(View.VISIBLE);
... | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create a new Component. | @SneakyThrows
public static void main(String args[]) {
Component component = new Component();
//Create a new HTTPS server listening on port 2709.
org.restlet.Server server = component.getServers().add(Protocol.HTTP, 4243);
Series<Parameter> params = server.getContext().getParameters... | [
"public void create() {\n interactableComponent = entity.getComponent(InteractableComponent.class);\n super.create();\n }",
"public GraphComp.Component newComponent() {\n return this._newComponent(new GraphComp.Requires() {}, true);\n }",
"public RobotsEcosystem.Component newComponent() {\r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
optional uint32 alert_type = 4; | public int getAlertType() {
return alertType_;
} | [
"public interface CLIENT_PROTOCOL_POLICY_TYPE {\n int value = 43;\n}",
"protected AlertProtocol() {}",
"NagiosAlertLevel getAlertSeverity();",
"public void alertOccurred(Alert alert);",
"private void recvAlert(InputRecord r) throws IOException {\n byte level = (byte) r.read();\n byte descri... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
creates a new activity which is the repair guide and passes the errorCode from the notification to populate guide | @Override
public void acceptClicked(View view, IncomingError incomingError) {
Intent intent = new Intent(getActivity(), RepairActivity.class);
RepairActivityData data = new RepairActivityData(incomingError.getErrorCode(),
incomingError.getRepairCode(), incomingError.getRepairTitle(),... | [
"private void createReading() {\n \tIntent i = new Intent(this, EditElectricity.class);\n \tstartActivityForResult(i, ACTIVITY_CREATE);\n }",
"private void newRecipe(){\n Intent i = new Intent(this, RecipeActivity.class);\n this.startActivityForResult(i, REQUEST_NEW_RECIPE);\n }",
"pub... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
put a new instance every time, so it is thread safe | public void set(String key, CacheValue value, int expInSec) throws CacheException {
cache.put(key, value);
} | [
"private void getInstance() {\n if (instance == null) {\n // Get an initialise the cache\n instance = new AbstractRUMMapTest.AbstractRUMMapImpl();\n\n try {\n // Get the instance\n instance.init(\"DBTestPipe\", \"AbstractRUMMapTest\");\n } catch (InitializationException ex) {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get user input from editor and save Item into database. | private boolean saveItem() {
// Read from input fields
// Use trim to eliminate leading or trailing white space
if(check()) {
String nameString = mNameEditText.getText().toString().trim();
String quantityString = mQuantityEditText.getText().toString().trim();
Str... | [
"private void saveItem() {\n // Read from input fields\n String nameString = mNameEditText.getText().toString().trim();\n String priceString = mPriceEditText.getText().toString().trim();\n String quantityString = mQuantityEditText.getText().toString().trim();\n String supplierName... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test case number: 70 /Coverage entropy=2.6948656316777955 | @Test(timeout = 4000)
public void test070() throws Throwable {
ErrorPage errorPage0 = new ErrorPage();
Component component0 = errorPage0.kbd();
Submit submit0 = new Submit(errorPage0, (String) null, (String) null);
Table table0 = new Table(submit0, (String) null);
Table table1 = table0... | [
"@Test(timeout = 4000)\n public void test147() throws Throwable {\n TextDirectoryLoader textDirectoryLoader0 = new TextDirectoryLoader();\n Instances instances0 = textDirectoryLoader0.getStructure();\n Evaluation evaluation0 = new Evaluation(instances0, (CostMatrix) null);\n String string0 = ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Reset the reader to start reading from scratch. | public abstract void reset() throws IOException; | [
"public void reset() {\n try {\n _reader.reset();\n } catch (Exception ignored) {\n }\n }",
"@Override\n public void reset() {\n this.resetReaders();\n }",
"protected void reset() {\n readPointer = 0;\n }",
"public void resetReadBuffer() {\r\n\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Helper method to check the output file is csv file. | private static Boolean checkCsvFile(String args) {
return args.toLowerCase().contains(".csv");
} | [
"private Boolean validateCsv(StringBuffer errorMessage,\n String output) {\n String expect = \".*\\\\.csv$\";\n if (!Pattern.matches(expect, output)) {\n errorMessage.append(\"Error: expect .csv file as input value, but not found.\"\n + \" Please check the Usage.\");... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Read data with vLille API | public List<StationDTO> performSynchronisation() throws SynchronisationException {
final VlilleDataSet dataSet = vService.getDataSet();
List<StationDTO> listeStation;
listeStation = metierVersContrat(dataSet);
return listeStation;
} | [
"private List<Vehicle> _read() {\n GtfsRealtime.FeedMessage msg = null;\n byte[] gtfs;\n List<Vehicle> vehicles = null;\n try (InputStream in = GetGtfs.feedUrlStream(optApiKey, optFeed, optUrl)) {\n gtfs = ByteStreams.toByteArray(in);\n msg = GtfsRealtime.FeedMessag... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Element that must be an ISO formatted timestamp | public PactDslJsonArray timestamp() {
String pattern = DateFormatUtils.ISO_DATETIME_FORMAT.getPattern();
body.put(DateFormatUtils.ISO_DATETIME_FORMAT.format(new Date(DATE_2000)));
generators.addGenerator(Category.BODY, rootPath + appendArrayIndex(0), new DateTimeGenerator(pattern));
matchers.add... | [
"private String _createISO8601Date(long timestamp) {\n\t\tString date = new SimpleDateFormat(\"yyyy-MM-dd'T'HH:mm:ssz\").format(new Date(timestamp * 1000));\n\t\treturn date.substring(0, 19) + date.substring(22, date.length());\n\t}",
"@ApiModelProperty(example = \"2017-07-21T17:32:28Z\", value = \"timestamp in I... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
add all cells that contain one of the levels ENGAGEMENT, APPLICATION, APPLICATIONCOMPONENT, LICENSE surrounded by to dataIterators with the cell as key and the level as value | private void findCellsToIterate(Map<Cell, String> dataIterators, Workbook wb, Collection<String> tableLabels) {
for (Sheet sheet : wb) {
for (Row row : sheet) {
for (Cell cell : row) {
if (cell.getCellType() == CellType.STRING) {
String cellText = cell.getStringCellValue();
... | [
"@Override\r\n\tpublic boolean init(){\n\t\tthis.bags = new HashMap<ExtendedMultiKey, MultiKeyBag>();\r\n\t\t\tif (!includeAll)\r\n\t\t\t\tthis.bagsOutside = new HashMap<ExtendedMultiKey, MultiKeyBag>();\r\n\r\n\t\t//holding all extended data per episode type and for patient extended data\r\n\t\tthis.bagsExtended =... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the customerFirstName value for this HostedDataRetrieveReply. | public void setCustomerFirstName(java.lang.String customerFirstName) {
this.customerFirstName = customerFirstName;
} | [
"public void setCustomerFirstName(String firstName) {\r\n\t\tthis.customerFirstName = firstName;\r\n\t}",
"public void setFirstName(String firstname) {\n\t\tthis.FirstName = firstname;\n\t}",
"public void setFirstName(String value)\r\n {\r\n firstName.set(value);\r\n }",
"public void setFirstName... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
write your code here | public static void main(String[] args) throws IOException {
SplitterEngine engine = new SplitterEngine();
engine.setSourceFile("TESTOWY_PLIK.txt");
String s = "ewqeqwe";
System.out.println( s == test(s));
engine.getNextSentense();
} | [
"void stuffForYouToDo() {\n\t\t// Write your code here...\n\t\t\n\t\t\n\t\t\n\t}",
"@Override\r\n\t\t\t\tvoid eval() {\r\n\r\n\t\t\t\t\t// YOUR CODE IN THIS SPACE\r\n\t\t\t\t}",
"private static void EX5() {\n\t\t\r\n\t}",
"@Override\n\tpublic void dosomethiing3() {\n\n\t}",
"@Override\n }",
"pu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Builds a new instance | public LayerFolderImpl(String name, File folder)
throws IllegalArgumentException, IOException {
super(name, folder);
} | [
"private void build() {\n }",
"public ObjectBuilder<?> build() {\n return new ObjectBuilder(runtime);\n }",
"private Builder() { }",
"abstract C build();",
"public Builder() {\r\n this.obj = new SourceInfo();\r\n }",
"public Negozio build() {\n\t\t\tNegozio negozio \t\t\t= n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
optional string gsjffs = 4; | public com.google.protobuf.ByteString
getGsjffsBytes() {
return instance.getGsjffsBytes();
} | [
"public void loadHex(String[] s){\n\t\tthis.name = s[0];\n\t\tthis.owner = s[1];\n\t\tthis.habitability = Double.parseDouble(s[2]);\n\t\tthis.alignment = s[3];\n\t\tthis.religion = s[4];\n\t\tthis.pop_size = Integer.parseInt(s[5]);\n\t\tthis.unrest = Integer.parseInt(s[6]);\n\t\tthis.resource = s[7];\n\t\tthis.reso... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates a class loader that can load JAXB/WS 2.2 API, and then return a class loader that can RI classes, which can see all those APIs. | public static ClassLoader createClassLoader(ClassLoader cl) throws ClassNotFoundException, IOException {
URL[] urls = findIstack22APIs(cl);
if(urls.length==0)
return cl; // we seem to be able to load everything already. no need for the hack
List<String> mask = new ArrayList<>(Arra... | [
"private AntClassLoader createClassLoader() {\n AntClassLoader loader = null;\n if (!JavaEnvUtils.isJavaVersion(JavaEnvUtils.JAVA_1_1)) {\n try {\n // 1.2+ - create advanced helper dynamically\n Class loaderClass\n = Class.forName(ANTCL... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
optional uint32 keepalivetime = 8; ms | public boolean hasKeepalivetime() {
return ((bitField0_ & 0x00000080) == 0x00000080);
} | [
"long remainTimeToLive();",
"public long getKeepTime() {\n return keepTime_;\n }",
"@Override\n\t\t\t\t\t\tpublic long getLastPingTime()\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treturn System.currentTimeMillis();\n\t\t\t\t\t\t}",
"protected long getHeartbeatDelay()\n {\n return 0;\n }",
"private i... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Instantiate and start the handler | public TherapyClientHandler(Socket socket, Therapist therapist){
socketBackToClient = socket;
this.therapist = therapist;
start();
} | [
"@Override\n\tpublic synchronized void start() {\n\t\tsuper.start();\n\t\tLooper looper = getLooper();\n\t\tmHandler = new Handler(looper){\n\n\t\t\t@Override\n\t\t\tpublic void handleMessage(Message msg) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\tswitch (msg.what) {\n\t\t\t\tcase 1:\n\t\t\t\t\tLog.i(TA... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Generated method Getter of the Product.b2bUnitLinks attribute. | public Collection<ProductB2BUnitLink> getB2bUnitLinks(final Product item)
{
return getB2bUnitLinks( getSession().getSessionContext(), item );
} | [
"public NEOLink getLinks() {\n return links;\n }",
"public List<String> getLinks()\n {\n return this.links;\n }",
"protected java.util.Vector _getLinks() {\n\tjava.util.Vector links = new java.util.Vector();\n\tlinks.addElement(getAction2divisionLink());\n\tlinks.addElement(getProtoActionsLink(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Comment inherited from interface | public void reset()
{
for (int i=0; i < snodes.length; i++) {
snodes[i] = null;
}
spos = 0;
for (int i=0; i < dnodes.length; i++) {
dnodes[i] = null;
}
dpos = 0;
} | [
"public interface Comment extends Node {\n\n void setData(String data);\n String getData();\n\n}",
"public abstract Comment getComment();",
"@Override\n public String getType() {\n return \"COMMENT\";\n }",
"public interface NearbyDetailsComment {\n\n /**\n * 周边详情评论\n * @param uid\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Processes requests for both HTTP GET and POST methods. | protected void processRequest(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
//VALIDAMOS QUE SE HALLA PRESIONADO EL BOTON DE GUARDAR
if (request.getParameter("btnGuardar") != null) {
btnGuardar(request, response);
} else... | [
"@Override\r\n protected void doGet(HttpServletRequest request, HttpServletResponse response)\r\n throws ServletException, IOException {\r\n Enumeration<String> parameterNames = request.getParameterNames(); //checking for unappropriate parameters\r\n if (parameterNames.hasMoreEleme... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public int confirmReturn(int rno) {
return mapper.confirmReturn(rno);
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
only run if database does not exist | @Override
public void onCreate(SQLiteDatabase db){
//create table "vehicle"
db.execSQL(
"create table " + VEHICLE_TABLE_NAME + "("+
VEHICLE_COLUMN_REGO + " text primary key, " +
VEHICLE_COLUMN_DISPLAY_NAME + " text, " +
... | [
"public boolean checkIfDatabaseExist() {\n\t\treturn this.getDatabase().checkDataBase();\n\t}",
"private boolean checkDataBase() {\r\n File dbFile = new File(DB_PATH + DB_NAME);\r\n return dbFile.exists();\r\n }",
"private void checkDatabase() {\r\n\tQuery query = QueryBuilder.Query().ShowDataBases().get... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Modificacion del paso hacia atras para soportar las especificaciones propias del enfoque totalmente descriptivo. | @Override
protected void backward_pass() throws NullPointerException, AnfisException{
if (mx==null || vy==null) throw new NullPointerException("Mx o Vy son nulos");
int i,j,p, numPat=mx.length;
double dMF_da[][]=new double [numRule][numVar],
dMF_db[][]=new double [numRule]... | [
"private void ComportarPoblacion() {\n\t\tPoblacion.getInstance().ComportarGeneracion();\n\t}",
"public void pasaportePrimero() {\n Nodo aux = cabeza;\n int cont = 0;\n\n while (aux != null) {\n if (pasaporteCedula(aux.getPersona().getCedula())) { //Cuenta cuantos pasaportes hay en... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
set item as selected to persist highlight | @Override
public boolean onNavigationItemSelected(@NonNull MenuItem menuItem) {
menuItem.setChecked(true);
// close drawer when item is tapped
drawerLayout.closeDrawers();
switch (menuItem.getItemId()) {
case R.id.openProfile:
openProfileFragment();
... | [
"public void setCurrentlySelectedItem(Thing item) {\n this.getModel().setObject(item);\n }",
"public void select() {\n setSelected(true);\n }",
"public void changeSelected()\n {\n if(selected)\n selected = false;\n else\n selected = true;\n }",
"public void se... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Disallows the given command | public void disallowCommand(String cmd) {
if (cmd == null || !getAllowedCommands().contains(cmd)) return;
getAllowedCommands().remove(cmd);
} | [
"public boolean deny(Request request);",
"protected abstract void doDisable();",
"public void invalidCommandType() {\r\n\t\tthis.gameEngine.getBrowser().println(\r\n\t\t\t\t\"What am I doing? I think I'm just shouting jibberish.\\n\" +\r\n\t\t\t\t\t\t\"I need to think carefully about what I do. I could do with ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the color model. | void setColorModel(ColorModel cm); | [
"public final void setColorModel(int cm) {\n\t\tcolorModel = cm;\n\t}",
"private void setColorModelGrey() {\n\t\t// Copy in the default colors\n for (int i = 0; i < tableSize; i++) {\n cm_red[i] = puke_red[i];\n cm_green[i] = puke_green[i];\n cm_blue[i] = puke_blue[i];\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by Abator for iBATIS. This method corresponds to the database table MI039 | int deleteByExample(Mi039Example example); | [
"public interface I_Z_Sys_Migracion \n{\n\n /** TableName=Z_Sys_Migracion */\n public static final String Table_Name = \"Z_Sys_Migracion\";\n\n /** AD_Table_ID=1000226 */\n public static final int Table_ID = MTable.getTable_ID(Table_Name);\n\n KeyNamePair Model = new KeyNamePair(Table_ID, Table_Name)... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Locate all Projects known by the TimeSheet system. | public ArrayList findAllProjects() throws ModelException; | [
"private static void getProjects() {\n\t\t\n\t}",
"private void loadOpenShiftProjects() {\n openShiftClient.getProjects().then(new Operation<List<Project>>() {\n @Override\n public void apply(List<Project> result) throws OperationException {\n if (result.isEmpty()) {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ access modifiers changed from: private | public void menuBottomStart() {
for (int i = 0; i < 5; i++) {
registerTouchArea((ITouchArea) this.buttonBottom.get(i));
((ButtonSprite) this.buttonBottom.get(i)).setPosition((float) (i * 108), 760.0f);
}
} | [
"@Override\n }",
"protected void method_5557() {}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n public void publicando() {\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"private InternalReflect() {\n\t\t\t// do nothing\n\t\t}",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
redraws the scene, and positions the sprite. | private void draw() {
double width = getWidth();
double height = getHeight();
controller.updateSpritePosition();
controller.positionExitsAndDisableButtons();
GraphicsContext gc = getGraphicsContext2D();
gc.clearRect(0, 0, width, height);
} | [
"public void updateSprite() {\r\n\t\tthis.controller.updateSprite();\r\n\t}",
"public void update() {\n position.update();\n sprite.update();\n }",
"@Override\n\tpublic void render() {\n\t\tsprite.update();\n\t}",
"public void repaint() {\n\t\tif(modelInterface.getState()!=state){\n\t\t\tif(m... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructor for DemeritDatastoreService Use an instance of this for creates, updates, retrievals. Use the getDatastore() method to get a DS reference for your queries. | public DemeritDatastoreService() {
ds = DatastoreServiceFactory.getDatastoreService();
} | [
"public DataService() {\n\t\tsuper(\"DataService\");\n\t\tLog.i(TAG, \"DataService instantiated\");\n\t\t// TODO Auto-generated constructor stub\n\t}",
"public AppEngineGuiceModule withDatastoreService()\r\n {\r\n this.datastoreService = DatastoreServiceFactory.getDatastoreService();\r\n this.asy... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by Apache iBATIS ibator. This method returns the value of the database column t_contract_product_detail.report_code | public String getReportCode() {
return reportCode;
} | [
"@ReportableProperty(order = 10, value = \"Result-Code header value.\")\r\n public String getResultCode() {\r\n return record.resultCode;\r\n }",
"public String getProductCode() {\r\n/* 115 */ return this._productCode;\r\n/* */ }",
"public String getCode() {\r\n return (String)getA... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Converts a evalue into an alpha value and uses the alpha value to make a color transparent. | public static Color createEvalueColor(Color color, double evalue) {
return new Color(color.getRed(), color.getGreen(), color.getBlue(), evalue2alpha(evalue));
} | [
"public Color alpha(float a) {\n\t\treturn set(getRed(), getGreen(), getBlue(), (int) (a * 255));\n\t}",
"private int getAlpha(double value)\n {\n double divisor = value >= 0 ? max : min;\n int alpha = (int)(75 * Math.abs(value / divisor) + 180);\n return Math.min(Math.max(alpha, 0), 255);... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
url httpconnection buffereader JSON | public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
System.out.println("Por favor introduce un nombre");
String nombre = scanner.nextLine();
ArrayList<Pais> listaPaises = new ArrayList<>();
try {
String urlTemplate = "https://api.nationa... | [
"private static String makeHttpRequest(URL url) throws IOException{\n\n String jsonResponse = \"\";\n\n if(url == null){\n return jsonResponse;\n }\n\n HttpURLConnection httpURLConnection = null;\n InputStream inputStream = null;\n\n try {\n httpURLCon... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Boilerplate to create a new string field with a given list of permitted values. | public static FieldDefinition enumStringField(String name, List<String> enumValues) {
return new FieldDefinition(name, typeString(null)).withCheck(new ValueInListCheck(enumValues));
} | [
"private static StringListField strList(String key, List<String> defaults) {\n return new StringListField(key, defaults);\n }",
"@CanIgnoreReturnValue\n public StructureBuilder addField(String name, ImmutableList<String> values) {\n fields.put(name, StringSequence.of(values));\n return this... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Reads the private key form the stream that was given in the constructor. After the reading, the file mark is at the end of the key. | public static PrivateKey read(final BufferedReader reader, final PasswordFinder finder) throws IOException {
try {
// TestBase.printInterval("start keyreader");
reader.mark(MARK_LEN);
// TestBase.printInterval("setup");
PEMRead... | [
"public LicenseKeyPair readPrivate(IOFormat format) throws IOException, InvalidKeySpecException, NoSuchAlgorithmException {\n return read(format, Modifier.PRIVATE);\n }",
"public KeyForDecryption(InputStream stream)\n throws IOException, PGPException {\n super(stream);\n }",
"private Priv... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method determines whether or not the SCO supports the ability to find an LMS provided API Adapter. | public boolean supportsFindAPI()
{
final boolean flag = mSCOSession.supportsFindAPI();
mLogger.finest("Find API Support: " + flag);
return flag;
} | [
"private boolean isSupportedInternal() {\n boolean z = false;\n if (this.DBG) {\n Log.d(TAG, \"isSupportedInternal\");\n }\n synchronized (this.mLock) {\n if (this.mServiceManager == null) {\n Log.e(TAG, \"isSupported: called but mServiceManager is nu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ so the cards should just be dealt from playerDeck to player bankerDeck to banker each player gets 1 card for their hands. | private void playGame() throws IOException {
//you only need to deal 1 card.
int numCards = 1;
CardHand playerHand=null, bankerHand=null;
// first a card from each deck is dealt to each players hand
playerHand = playerDeck.dealHand(numCards); bankerHand = bankerDeck.dealHand(numCards);
//the hands a... | [
"private void dealCardsToPlayers(Deck deck){\n\t\t//This for loop deals out cards to the players which then adds the card to each players respective pile\n\t\tfor(int i = 0; i < 52; i++){\n\t\t\t//adds the card to the respective players cardpile\n\t\t\tplayer1.addCardToPile(deck.dealTopCard());\n\t\t\ti++;\n\t\t\tp... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Number of times the hash table is searched. Constructor for the MyHashTable class | public MyHashTable(int size){
table = new LinkedList[size]; //Initialize the table of 10,000 Linked lists.
} | [
"int getHashmapCount();",
"public HashTable() {\n\n // Assign values to field members\n this.numKeys = 0;\n this.tableSize = 11;\n this.loadFactorThreshold = 0.75;\n this.loadFactor = 0;\n\n // Initialize table with bucket space for arrays.\n this.table = new Object[this.tableSize];\n }",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Posts notification to be shown. Makes sure that the service runs in the foreground for ongoing notifications. | public synchronized void notify(int id, Notification notification) {
// notifications that are not "ongoing" cannot be raised with
// the startForeground API.
final boolean ongoingEvent = (notification.flags & FLAG_ONGOING_EVENT) != 0;
if (foregroundWasSet || !ongoingEvent) {
... | [
"private void showNotification() {\r\n\t\t// In this sample, we'll use the same text for the ticker and the expanded notification\r\n\t\tCharSequence text = getText(R.string.service_text);\r\n\r\n\t\t// Set the icon, scrolling text and timestamp\r\n\t\tnotification = new Notification(R.drawable.icon, text, System.c... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns a set of all outgoing edges of nodes. | private Set<Graph.Edge<PlacedData<Integer>,Integer>> getAdjacencyEdges() {
for (Graph.Node<PlacedData<Integer>,Integer> node : unvisited) {
adjacencies.addAll(node.getOutgoingEdges());
}
return adjacencies;
} | [
"public Collection<Edge<V>> getOutEdges(Node<V> source) {\r\n\t\treturn graph.get(source);\r\n\t}",
"public Collection<ObservationEdge> getAllOutgoingObservations () {\n\t\treturn outgoingEdges.values();\n\t}",
"private Set<NodeEdge> getNodeEdges() {\n return Collections.unmodifiableSet(edgeSet().stream(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the quality of this item. Quality is specified by an integer: 0 (new) or 1 (used). | public int getQuality() {
return quality;
} | [
"public int getQuality(){\n\t\treturn checkZero(get(QUALITY));\n\t}",
"public Integer getQualityCost() {\n return qualityCost;\n }",
"public com.google.protobuf.ByteString\n getQualityBytes() {\n Object ref = quality_;\n if (ref instanceof String) {\n com.google.protobuf.ByteSt... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Add a service to the Flexibook | public static void addService(String name, String duration_Str, String downtimeDuration_Str, String downtimeStart_Str)
throws InvalidInputException {
String error = "";
FlexiBook flexibook = FlexiBookApplication.getFlexiBook();
User currentUser = FlexiBookApplication.getCurrentUser();
int duration = 0;
in... | [
"public void addService(Class<?> service){\r\n\t\t services.add(service);\r\n\t }",
"void addService(String name) {\n if (services.add(namePrefix + name)) {\n closeWatch();\n }\n }",
"public void addService(Service service) {\r\n\t\tthis.getServiceList().add(service);\r\n\t}",
"void re... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Feed some null parameters in and make sure that they're not null when you read them back | public void testNullParameters() throws ParseException
{
FeedItem item = new FeedItem(nswTestDate1,title, link, guid, null, null,null,null);
String readDate = item.getDate();
assertTrue(nswTestDate1.equals(readDate));
String readTitle = item.getTitle();
asse... | [
"protected boolean checkNull() {\n return false;\n }",
"@Override\n\tpublic void flagNull() {\n\n\t\t\n\t}",
"public void hasSaneValues() {\n\t\tif (aifirm == null || aiorg == null || aipwd == null || aipath == null || aiapi == null || aiuser == null || aiupwd == null || aihost == null || aiauur == n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public T queue() {
return arr[queue];
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Takes single backward processing step to process layer output gradient(s) towards input. Applies automated backward (automatic gradient) procedure when relevant to layer. | public void backwardProcess() throws MatrixException, DynamicParamException {
if (procedure != null) procedure.calculateGradient(getLayerOutputGradients(), getInputGradientSequences(), getTruncateSteps());
} | [
"@Override\n\tpublic boolean backPropagate(double[] nextBiasGradient, double[][] nextWeights) {\n\t\t// calculate the bias gradient and weights gradients\n\t\tdouble[] biasGradient = calculateBiasGradient(nextBiasGradient, nextWeights);\n\t\tcalculateWeightGradient(prevLayer.activation, biasGradient);\n\t\t// pass ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Reset the database to start fresh | static public void reset() {
if (LOCAL_LOG) {
Log.i(TAG, "Reset relations table");
}
FormRelationsDb frdb = new FormRelationsDb();
SQLiteDatabase db = frdb.getWritableDatabase();
db.execSQL(FormRelations.DELETE_TABLE);
db.execSQL(FormRelations.CREATE_TABLE);
... | [
"private void resetDB() {\n PsqlDBHelper psqlDBHelper = new PsqlDBHelper();\n if(psqlDBHelper.checkTable(\"flussorighesp\")) {\n psqlDBHelper.deleteTable(\"flussorighesp\");\n psqlDBHelper.createTableFlussoSp();\n }\n psqlDBHelper.closeConnection();\n }",
"publ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public Image getImage(Object element) {
return null;
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
using Longest common subsequence | static void LCSApproach(char str1[], char str2[], int n, int m){
LongestCommonSubsequence lcs=new LongestCommonSubsequence();
int lcsLen = lcs.recursive(str1, str2,n,m);
System.out.println("\n ------- Using longest common subsequence approach ---------------");
System.out.println("\t Mi... | [
"public static void main(String[] args) {\n\n List<String> s1 = new ArrayList<String>(\n Arrays.asList(\"ABCDGH\".split(\"\")));\n List<String> s2 = new ArrayList<String>(\n Arrays.asList(\"AEDFHR\".split(\"\")));\n\n System.out.println(s1);\n System.out.pri... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
TODO Autogenerated method stub | @Override
public void processMessageReceived(ChannelHandlerContext ctx, NettyCommand msg) {
} | [
"@Override\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"@Override\n\t\tpublic void kayit1() {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void wydaj() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the city_nxx_prefix value for this City. | public java.lang.String getCity_nxx_prefix() {
return city_nxx_prefix;
} | [
"public int getPrefix() {\n \treturn Integer.parseInt(this.getNr().toString().substring(0, Anacom.prefixLength)); \t\n }",
"public final String getPrefix() {\r\n return this.m_prefix;\r\n }",
"public String getPrefix() {\n return (this.prefix);\n }",
"public String getNameSpacePrefix()\r\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This callback may be called twice, once for the cache and once for loading the data from the server API, so we check before decrementing, otherwise it throws "Counter has been corrupted!" exception. | @Override
public void onTransactionsLoaded(List<Transaction> transactions) {
if (!EspressoIdlingResource.getIdlingResource().isIdleNow()) {
EspressoIdlingResource.decrement(); // Set app as idle.
}
processTransactions(transactions);
... | [
"private void deleteCounter(Integer data) {\n\t\t\n\t}",
"public void incrementMiss() {\n Cache.incMiss(); }",
"private void decreaseCounter() {\n this.hitsCounter -= 1;\n }",
"private UnreadMessagesCounter() {\n\t}",
"protected int decrementInitializationCount() {\r\n l.entering(get... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the builder for the settings used for calls to createReport. | public UnaryCallSettings.Builder<CreateReportRequest, Operation> createReportSettings() {
return getStubSettingsBuilder().createReportSettings();
} | [
"public UnaryCallSettings.Builder<GetReportRequest, Report> getReportSettings() {\n return getReportSettings;\n }",
"public POGOProtos.Rpc.ProbeSettingsProto.Builder getProbeSettingsBuilder() {\n \n onChanged();\n return getProbeSettingsFieldBuilder().getBuilder();\n }",
"public POGOPr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
If player lands on start increase money with 4000 | @Override
public void Lands(Player P)
{
P.ChangeMoney(4000);
} | [
"public void passGO() {\r\n \tmoney = money + 200;\r\n }",
"void withdrawMoney(Player player, double amount);",
"public void reward(long money) {\n this.money += money;\n }",
"public void increaseMoney(double amount) {\r\n money += amount;\r\n }",
"public void buyHp(int amount) {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ access modifiers changed from: protected | public void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
boolean remeasureTabWidth = this.mTabs != null && this.mTabs.getLayoutParams().width <= 0;
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
if (remeasureTabWidth) {
int contentWidth = ((View) this.mAppsCustomiz... | [
"@Override\n }",
"protected void method_5557() {}",
"@Override\n public void extornar() {\n \n }",
"@Override\r\n public void publicando() {\n }",
"@Override\n\t\t\t\tpublic void pintate() {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\r\n\tpublic void hablar() {\n\t\t\r\n\t}",
"pro... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
optional int32 player_id_1 = 1; | public Builder setPlayerId1(int value) {
bitField0_ |= 0x00000001;
playerId1_ = value;
onChanged();
return this;
} | [
"public int getPlayerID() {return playerID;}",
"public int getId() {\r\n return player_id;\r\n }",
"public Integer getPlayerid() {\n return playerid;\n }",
"@Override\n\tpublic int getPlayerId() {\n\t\treturn 0;\n\t}",
"int getPlayerId() {\n return playerId;\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ renamed from: a | public static void m14048a(Context context, C6908a imageListener, String url, Bitmap fallbackImage) {
C13797m.create(new C6906f(context, url, fallbackImage)).subscribeOn(C13777b.m43848c()).observeOn(C13187b.m43117a()).subscribe((C13804t<? super T>) new C6905e<Object>(imageListener));
} | [
"public interface C3511a {\n /* renamed from: a */\n void mo29057a(int i);\n }",
"interface C4511c {\n /* renamed from: a */\n void mo29775a();\n }",
"public interface ans {\n /* renamed from: a */\n void mo1174a();\n}",
"public interface C24712af {\n /* renamed from... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
checks, if the parts of the matches really occur in subsequent positions for searches with word lenghts > n | public static HashSet<Integer> checkHashSets(ArrayList<HashSet<Integer>> list, int parts) {
HashSet<Integer> results = new HashSet<Integer>();
//if there's any match at all -> as many elements in partMatches as there are parts of the original word
if(list.size() == parts) {
HashSet<Integer> firstSe... | [
"static long substrCount(int n, String s) {\r\n \tlong b = s.length();\r\n \tfor(int i=0;i<s.length();i++) {\r\n \t\t//System.out.println(b);\r\n \t\tint k=i;\r\n \t\tint y=k+2;\r\n \t\tboolean a=false;\r\n \t\twhile(y<=n && isSame(s.substring(k, y))) {\r\n \t\t\ty++;\r\n \t\t\tb++;\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Method to check if dialog sheet is visible | public boolean isShowing(){
if(dialog!=null) {
return dialog.isShowing();
}else{
return false;
}
} | [
"boolean isDialogVisible();",
"public boolean isVisible() {\n if (mSearchDialog != null) {\n return mSearchDialog.isShowing();\n }\n return false;\n }",
"@Override\n\tpublic boolean isShowing() {\n\t\treturn spreadsheetWrapper.isVisible() && spreadsheetWrapper.isAttached()\n\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Adds an order to the list of orders. | public static void addOrder(Order order) {
orderList.add(order);
} | [
"public void addOrder(ThingsToOrder order) {\n\t\tthis.wallet.add(order);\n\t}",
"@Override\r\n\tpublic void add(Order order) {\n\t\torder.setCreateDate(new Date());\r\n\r\n\t\torder.setOrderCode(order.getOrderCode());\r\n\t\torderMapper.insert(order);\r\n\t}",
"public void add(ItemOrder order) {\n // first ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |