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
/ Converts the JSONObject into binary so that it can be sent to the frontend.
public byte[] toBinary(JSONObject message) { String messageToConvert = message.toString(); byte[] converted = null; try { converted = messageToConvert.getBytes("UTF-8"); } catch (UnsupportedEncodingException e) { e.printStackTrace(); } return converted; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n public byte[] toBinary(Object obj) {\r\n return JSON.toJSONBytes(obj, SerializerFeature.WriteClassName);\r\n }", "public static final byte[] toBytesHardcoded(JSONObject json) throws JSONException, IOException{\n\t\tByteArrayOutputStream out = new ByteArrayOutputStream(1200);\n//\t\tByt...
[ "0.64149857", "0.63853645", "0.61381257", "0.61075187", "0.5845067", "0.5835534", "0.5762277", "0.57566994", "0.57274216", "0.5642492", "0.56031", "0.55807036", "0.5564868", "0.5511012", "0.5504633", "0.5504633", "0.5504633", "0.5439083", "0.5421587", "0.541042", "0.5380975",...
0.6957704
0
Add code to print out the key hash
protected void printFaceBookKeyHash() { try { PackageInfo info = getPackageManager().getPackageInfo("com.sakewiz.android", PackageManager.GET_SIGNATURES); for (Signature signature : info.signatures) { MessageDigest md = MessageDigest.getInstance("SHA"); md.update(signature.toByteArray()); Log.d("KeyHash: ", Base64.encodeToString(md.digest(), Base64.DEFAULT)); } } catch (PackageManager.NameNotFoundException e) { e.printStackTrace(); } catch (NoSuchAlgorithmException e) { e.printStackTrace(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void printKeyHash() {\n try {\n PackageInfo info =\n getPackageManager().getPackageInfo(\"in.peerreview.ping\", PackageManager.GET_SIGNATURES);\n for (Signature signature : info.signatures) {\n MessageDigest md = MessageDigest.getInstance(\"SHA\");\n md.update(signature....
[ "0.7531474", "0.7494289", "0.74770004", "0.7221771", "0.71993643", "0.71375215", "0.69238776", "0.6626864", "0.658107", "0.657372", "0.657372", "0.6566303", "0.65651417", "0.65602124", "0.65358335", "0.6533007", "0.6529128", "0.65272707", "0.651566", "0.64898986", "0.64350915...
0.7103356
6
/ TSnackbar snackbar = TSnackbar.make(findViewById(android.R.id.content), message, TSnackbar.LENGTH_LONG); View snackbarView = snackbar.getView(); snackbarView.setBackgroundColor(bColor); TextView textView = (TextView) snackbarView.findViewById(com.androidadvance.topsnackbar.R.id.snackbar_text); textView.setTextColor(Color.WHITE); textView.setGravity(Gravity.CENTER); snackbar.show();
protected void showTopSnackBar(String message, int bColor) { Snackbar snack = Snackbar.make(getWindow().getDecorView().findViewById(android.R.id.content), message, Snackbar.LENGTH_LONG); View snackbarView = snack.getView(); snackbarView.setBackgroundColor(bColor); // TextView textView = (TextView) snackbarView.findViewById(com.androidadvance.topsnackbar.R.id.snackbar_text); // textView.setTextColor(Color.WHITE); // textView.setGravity(Gravity.CENTER_HORIZONTAL); // FrameLayout.LayoutParams params =(FrameLayout.LayoutParams)snackbarView.getLayoutParams(); // params.gravity = Gravity.TOP; // snackbarView.setLayoutParams(params); snack.show(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void showGreenSnackbar(String message, Activity activity, int snackbarDuration) {\n snackbar = Snackbar.make(activity.findViewById(android.R.id.content), message, snackbarDuration);\n View snackbarView = snackbar.getView();\n snackbarView.setBackgroundColor(Color.parseColor(GREEN...
[ "0.76668394", "0.7586835", "0.7286583", "0.72123903", "0.71448624", "0.69642085", "0.69192994", "0.6784911", "0.674164", "0.6686757", "0.6650013", "0.6630117", "0.6626679", "0.65759826", "0.6532154", "0.6502844", "0.64916664", "0.6388859", "0.6330665", "0.6308483", "0.6302625...
0.8008279
0
Calculate pay overrides the abstract method from Employee and calculates pay for commission employee
@Override public double calculatePay () { double commissionPay = this.sales * this.rate / 100; return commissionPay; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public double calculateSalary(){\n return this.horas_trabajadas*EmployeeByHours.VALOR_HORA;\n }", "public abstract double pay();", "public double calculatePay() \r\n\t{\r\n\t\treturn (payRate*hoursWorked);\r\n\t}", "@Override\n\tpublic int calculateSalary() {\n\t\treturn this.getPaym...
[ "0.68732584", "0.68290526", "0.68057346", "0.66378725", "0.66370064", "0.66082186", "0.650013", "0.6490196", "0.6455685", "0.64218634", "0.64210176", "0.6354296", "0.6350745", "0.63399565", "0.6316975", "0.62915397", "0.62558615", "0.62172157", "0.6204635", "0.6188878", "0.61...
0.728103
0
Overridden toString method to format employee info for commission employee
@Override public String toString () { String format = "Employee %s: %s , %s\n Commission Rate: $%.1f\n Sales: $%.2f\n"; return String.format(format, this.getId(), this.getLastName(), this.getFirstName(), this.getRate(), this.getSales()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String toString() {\n\t\treturn String.format( \"%s: %s\\n%s: $%,.2f; %s:%.2f\",\r\n\t\t\t\t \"commission employee\", super.toString(),\r\n\t\t\t\t \"gross sales\", getGrossSales(),\r\n\t\t\t\t \"commission rate\", getCommissionRate() );\r\n\t}", "public String toString()\n\t//return employee values\n\t{\...
[ "0.80933416", "0.80100036", "0.7956418", "0.7893493", "0.7860261", "0.77443665", "0.773744", "0.77250373", "0.7722408", "0.770877", "0.76997226", "0.76879317", "0.7682614", "0.7678641", "0.7663086", "0.76371723", "0.7611684", "0.75865406", "0.75673676", "0.7558208", "0.752331...
0.7897771
3
Overloaded toString method that accpets an int to format employee payroll for commission employee
@Override public String toString (int num) { String format = "Weekly pay for %s, %s employee id %s is $%.2f\n"; return String.format(format, this.getLastName(), this.getFirstName(), this.getId(), this.calculatePay()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String toString(){\r\n return String.format(\"%-15s%-15s%-30s%,8.2f\", this.employeeFirstName, \r\n this.employeeLastName, this.employeeEmail, getBiweeklySalary());\r\n }", "@Override //indicates that this method overrides a superclass method\n public String toString(){\n\n ...
[ "0.68772316", "0.6797047", "0.6774361", "0.67402077", "0.6653702", "0.6640315", "0.6594974", "0.65827584", "0.6548783", "0.654155", "0.6535344", "0.64966375", "0.6486427", "0.64504284", "0.64087796", "0.6332633", "0.63141376", "0.62992346", "0.62944067", "0.6292692", "0.62916...
0.728956
0
Mandatory empty constructor for the fragment manager to instantiate the fragment (e.g. upon screen orientation changes).
public TextFragment() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public FragmentMy() {\n }", "public RickAndMortyFragment() {\n }", "public MainActivityFragment() {\n }", "public MainActivityFragment() {\n }", "public RegisterFragment() {\n // Required empty public constructor\n }", "public VehicleFragment() {\r\n }", "public EmployeeFragmen...
[ "0.8031511", "0.76991963", "0.7676922", "0.7676922", "0.7538628", "0.7534647", "0.75326765", "0.75220966", "0.75071454", "0.74123853", "0.7406797", "0.737607", "0.73755896", "0.736607", "0.73266673", "0.73027587", "0.73027587", "0.72954965", "0.7287682", "0.728533", "0.728096...
0.0
-1
C L I C K
@Override public void onListItemClick(@NonNull final ListView listView, @NonNull final View view, final int position, final long id) { super.onListItemClick(listView, view, position, id); Log.d(TAG, "CLICK id=" + id + " pos=" + position); // cursor final ListAdapter adapter = getListAdapter(); assert adapter != null; final Object item = adapter.getItem(position); final Cursor cursor = (Cursor) item; // args Bundle args = getArguments(); assert args != null; // search target final String database = args.getString(ProviderArgs.ARG_QUERYDATABASE); if (database != null) { // wordnet switch (database) { case "wn": String subtarget = args.getString(ProviderArgs.ARG_QUERYIDTYPE); if ("synset".equals(subtarget)) { // recursion final int recurse = Settings.getRecursePref(requireContext()); // target final int colIdx = cursor.getColumnIndex("synsetid"); final long targetId = cursor.getLong(colIdx); Log.d(TAG, "CLICK wn synset=" + targetId); // build pointer final Parcelable synsetPointer = new SynsetPointer(targetId); // intent final Intent targetIntent = new Intent(requireContext(), org.sqlunet.wordnet.browser.SynsetActivity.class); targetIntent.setAction(ProviderArgs.ACTION_QUERY); targetIntent.putExtra(ProviderArgs.ARG_QUERYTYPE, ProviderArgs.ARG_QUERYTYPE_SYNSET); targetIntent.putExtra(ProviderArgs.ARG_QUERYPOINTER, synsetPointer); targetIntent.putExtra(ProviderArgs.ARG_QUERYRECURSE, recurse); // start startActivity(targetIntent); } else if ("word".equals(subtarget)) { // target final int colIdx = cursor.getColumnIndex("wordid"); final long targetId = cursor.getLong(colIdx); Log.d(TAG, "CLICK wn word=" + targetId); // build pointer final Parcelable wordPointer = new WordPointer(targetId); // intent final Intent targetIntent = new Intent(requireContext(), org.sqlunet.wordnet.browser.WordActivity.class); targetIntent.setAction(ProviderArgs.ACTION_QUERY); targetIntent.putExtra(ProviderArgs.ARG_QUERYTYPE, ProviderArgs.ARG_QUERYTYPE_WORD); targetIntent.putExtra(ProviderArgs.ARG_QUERYPOINTER, wordPointer); // start startActivity(targetIntent); } break; case "vn": // { final int idClasses = cursor.getColumnIndex(VerbNetContract.Lookup_VnExamples_X.CLASSES); final String classes = cursor.getString(idClasses); Log.d(TAG, "CLICK vn classes=" + classes); final Pair<TypedPointer[], CharSequence[]> result = makeData(classes); if (result.first.length > 1) { final DialogInterface.OnClickListener listener = (dialog, which) -> { // which argument contains the index position of the selected item final TypedPointer typedPointer = result.first[which]; startVn(typedPointer); }; final AlertDialog dialog = makeDialog(listener, result.second); dialog.show(); } else if (result.first.length == 1) { final TypedPointer typedPointer = result.first[0]; startVn(typedPointer); } break; } case "pb": // { final int idRoleSets = cursor.getColumnIndex(PropBankContract.Lookup_PbExamples_X.ROLESETS); final String roleSets = cursor.getString(idRoleSets); Log.d(TAG, "CLICK pb rolesets=" + roleSets); final Pair<TypedPointer[], CharSequence[]> result = makeData(roleSets); if (result.first.length > 1) { final DialogInterface.OnClickListener listener = (dialog, which) -> { // which argument contains the index position of the selected item final TypedPointer typedPointer = result.first[which]; startPb(typedPointer); }; final AlertDialog dialog = makeDialog(listener, result.second); dialog.show(); } else if (result.first.length == 1) { final TypedPointer typedPointer = result.first[0]; startPb(typedPointer); } break; } case "fn": // { final int idFrames = cursor.getColumnIndex(FrameNetContract.Lookup_FTS_FnSentences_X.FRAMES); final int idLexUnits = cursor.getColumnIndex(FrameNetContract.Lookup_FTS_FnSentences_X.LEXUNITS); final int idSentenceId = cursor.getColumnIndex(FrameNetContract.Lookup_FTS_FnSentences_X.SENTENCEID); final String frames = cursor.getString(idFrames); final String lexUnits = cursor.getString(idLexUnits); final String sentence = "sentence@" + cursor.getString(idSentenceId); Log.d(TAG, "CLICK fn frames=" + frames); Log.d(TAG, "CLICK fn lexunits=" + lexUnits); Log.d(TAG, "CLICK fn sentence=" + sentence); final Pair<TypedPointer[], CharSequence[]> result = makeData(frames, lexUnits, sentence); if (result.first.length > 1) { final DialogInterface.OnClickListener listener = (dialog, which) -> { // which argument contains the index position of the selected item final TypedPointer typedPointer = result.first[which]; startFn(typedPointer); }; final AlertDialog dialog = makeDialog(listener, result.second); dialog.show(); } else if (result.first.length == 1) { final TypedPointer typedPointer = result.first[0]; startFn(typedPointer); } break; } } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "C key();", "java.lang.String getCit();", "private boolean kcss(int[] i, long[] e, long y) {\n int I = i.length;\n long[] x = new long[I];\n while (true) {\n x[0] = ll(i[0]); // 1\n snapshot(i, 1, I, x); // 2\n if (Arrays.compare(x, e) != 0) { // 3\n sc(i[0], x[0]); // 3a\n ...
[ "0.61339355", "0.58528674", "0.58223134", "0.581035", "0.5796656", "0.5702882", "0.5676563", "0.56741226", "0.5663211", "0.56593764", "0.5657155", "0.55894977", "0.5582074", "0.55652744", "0.55499643", "0.5506032", "0.5480838", "0.54610515", "0.5453316", "0.5445156", "0.54310...
0.0
-1
Gets the changeOperation value for this HostIpRouteOp.
public java.lang.String getChangeOperation() { return changeOperation; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getOperation() {\n\t\t\treturn operation;\n\t\t}", "public String getOperation() {\n\t\treturn operation;\n\t}", "public String getOperation() {\n return operation;\n }", "public String getOperation() {\n return operation;\n }", "public String getOperation() {\r\n\t\tretur...
[ "0.6263187", "0.62191504", "0.62049407", "0.62049407", "0.61995405", "0.61984754", "0.61373246", "0.6117219", "0.6117219", "0.61061114", "0.60595095", "0.6032995", "0.5976228", "0.59418327", "0.5920344", "0.59106547", "0.58823955", "0.58823955", "0.5864094", "0.58504206", "0....
0.67946184
0
Sets the changeOperation value for this HostIpRouteOp.
public void setChangeOperation(java.lang.String changeOperation) { this.changeOperation = changeOperation; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setOperation(Operation operation) {\n this.operation = operation;\n }", "public void setOperation(OperationType operation) {\r\n this.operation = operation;\r\n }", "public void setOperation(OperationType operation) {\r\n this.operation = operation;\r\n }", "public v...
[ "0.57139236", "0.55487597", "0.55487597", "0.5530415", "0.55032957", "0.5380094", "0.53754246", "0.53754246", "0.5373167", "0.5373167", "0.5363493", "0.5360921", "0.5360921", "0.5328533", "0.53279716", "0.5240058", "0.5092996", "0.50326455", "0.49734882", "0.495319", "0.49470...
0.6234239
0
Gets the route value for this HostIpRouteOp.
public com.vmware.converter.HostIpRouteEntry getRoute() { return route; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getRoute() {\n return route;\n }", "public java.lang.String getRoute () {\n\t\treturn route;\n\t}", "@java.lang.Override\n public com.google.cloud.networkmanagement.v1beta1.RouteInfo getRoute() {\n if (routeBuilder_ == null) {\n if (stepInfoCase_ == 7) {\n return...
[ "0.64498746", "0.6370806", "0.6144719", "0.6142357", "0.61281043", "0.60312414", "0.601599", "0.5960937", "0.5956554", "0.587403", "0.5851939", "0.5848332", "0.58001053", "0.5768938", "0.56986505", "0.5611055", "0.560677", "0.5600572", "0.5599674", "0.556124", "0.5482772", ...
0.7511105
0
Sets the route value for this HostIpRouteOp.
public void setRoute(com.vmware.converter.HostIpRouteEntry route) { this.route = route; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setRoute(Route route) {\n this.route = route;\n }", "void setRoute(String routeID);", "public void setRoute(String route) {\n this.route = route == null ? null : route.trim();\n }", "void setRoute(Shape route);", "public void setRoute (java.lang.String route) {\n\t\tthis.rou...
[ "0.6525562", "0.64270276", "0.61834913", "0.61569214", "0.6024185", "0.59132355", "0.5667964", "0.5567192", "0.5483532", "0.54099494", "0.53998464", "0.53991205", "0.53835243", "0.509425", "0.50867766", "0.506784", "0.50194114", "0.50194114", "0.5017983", "0.49744165", "0.495...
0.77695006
0
Return type metadata object
public static org.apache.axis.description.TypeDesc getTypeDesc() { return typeDesc; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public MetadataType getType();", "public MetadataType getType() {\n return type;\n }", "public MilanoTypeMetadata.TypeMetadata getMetadata()\n {\n if (typeMetadata == null) {\n return null;\n }\n\n return typeMetadata;\n }", "private Metadata getMetadata(RubyModule type)...
[ "0.7969707", "0.7373198", "0.7358018", "0.7090138", "0.67353225", "0.67259765", "0.66725683", "0.65644145", "0.6543223", "0.6543223", "0.6543223", "0.6543223", "0.6543223", "0.6543223", "0.6543223", "0.6543223", "0.6543223", "0.6543223", "0.6543223", "0.6543223", "0.6543223",...
0.0
-1
Applies JText boxes to a Jpanel for UI
public static void createUI (JTextField fName, JTextField lName, JTextField vDesc, JTextField cLoc, JTextField dLoc, JTextField pNum, JPanel panel) { panel.setLayout(new BoxLayout(panel, BoxLayout.Y_AXIS)); panel.setAlignmentX(Component.LEFT_ALIGNMENT); panel.add(new JLabel("First Name:")); panel.add(fName); panel.add(Box.createHorizontalStrut(15)); // a spacer panel.add(new JLabel("Last Name:")); panel.add(lName); panel.add(new JLabel("Vehicle Description:")); panel.add(vDesc); panel.add(new JLabel("Pick Up Location")); panel.add(cLoc); panel.add(new JLabel("Drop Off Location")); panel.add(dLoc); panel.add(new JLabel("Phone Number")); panel.add(pNum); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void createTextPanel()\n\t{\t\t\n\t\ttextPanel.setLayout (new BorderLayout());\n\t\ttextPanel.add(entry, BorderLayout.CENTER);\n\t\t\n\t}", "private void $$$setupUI$$$() {\n mainPanel = new JPanel();\n mainPanel.setLayout(new GridLayoutManager(4, 2, new Insets(10, 10, 10, 10), -1, -1));\n ...
[ "0.68099433", "0.6591359", "0.6560067", "0.65417683", "0.65353465", "0.6533045", "0.6520706", "0.65147346", "0.64512396", "0.6435456", "0.6419991", "0.63771904", "0.6326056", "0.63100636", "0.6300175", "0.61995393", "0.6159212", "0.6153385", "0.61249655", "0.6095596", "0.6092...
0.5792673
66
/ For you to do: Using do while loop print even numbers from 20 to 1 Expected Output: 20 18 16 14 12 10 8 6 4 2
public static void main(String[] args) { int i = 20; do { if (i%2==0) System.out.println(i); i--; }while (i>1); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void main(String[] args) {\nint i =1;\r\nfor(i=1; i<=20; i++)\r\n{\r\n\tif(i % 2 == 1)\r\nSystem.out.println(i);\r\n}\r\nSystem.out.println(\"Printing only the odd numbers from 1 to 20\");\r\n\t}", "public static void main(String[] args) {\n\n\t int even=20;\n\t do {\n\t\tSystem.out.println(even);\...
[ "0.78823197", "0.76442134", "0.71807384", "0.71797407", "0.71573126", "0.7140301", "0.70796055", "0.7050541", "0.6962102", "0.6940095", "0.6940084", "0.69366133", "0.69271874", "0.68314576", "0.68084854", "0.67785156", "0.67517805", "0.6746516", "0.6727639", "0.66812295", "0....
0.77522844
1
/ Retrofit get annotation with our URL And upload image
@Multipart @POST() Call<Result> uploadImage(@Part MultipartBody.Part file, @Url String medialUploadUrl, @PartMap() Map<String, RequestBody> partMap);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@FormUrlEncoded\n @POST(\"upload.php\")\n Call<ImageClass> uploadImage(@Field(\"title\") String title, @Field(\"image\") String image);", "public interface ApiInterface {\n\n // this method commuticate with API\n\n\n @FormUrlEncoded\n @POST(\"upload.php\")\n Call<ImageClass> uploadImage(@Field(...
[ "0.6959435", "0.6817042", "0.6599501", "0.6474616", "0.6459815", "0.6448849", "0.64319265", "0.6413578", "0.6412175", "0.6395576", "0.6304611", "0.6301955", "0.6271656", "0.62420774", "0.6162394", "0.6118096", "0.6115538", "0.6080425", "0.60628515", "0.6058338", "0.60547185",...
0.61783844
14
A collection page for DeviceHealthScriptDeviceState
public DeviceHealthScriptDeviceStateCollectionPage(@Nonnull final DeviceHealthScriptDeviceStateCollectionResponse response, @Nonnull final DeviceHealthScriptDeviceStateCollectionRequestBuilder builder) { super(response, builder); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public DeviceHealthScriptDeviceStateCollectionPage(@Nonnull final java.util.List<DeviceHealthScriptDeviceState> pageContents, @Nullable final DeviceHealthScriptDeviceStateCollectionRequestBuilder nextRequestBuilder) {\n super(pageContents, nextRequestBuilder);\n }", "List<? extends IDeviceState> getDev...
[ "0.70607716", "0.60121596", "0.5517222", "0.5498726", "0.54802305", "0.53342175", "0.53286576", "0.53270227", "0.51817787", "0.5109856", "0.5073831", "0.506249", "0.5056763", "0.49703187", "0.49655145", "0.4951488", "0.49435148", "0.49364278", "0.48813462", "0.48803547", "0.4...
0.73560774
0
Creates the collection page for DeviceHealthScriptDeviceState
public DeviceHealthScriptDeviceStateCollectionPage(@Nonnull final java.util.List<DeviceHealthScriptDeviceState> pageContents, @Nullable final DeviceHealthScriptDeviceStateCollectionRequestBuilder nextRequestBuilder) { super(pageContents, nextRequestBuilder); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public DeviceHealthScriptDeviceStateCollectionPage(@Nonnull final DeviceHealthScriptDeviceStateCollectionResponse response, @Nonnull final DeviceHealthScriptDeviceStateCollectionRequestBuilder builder) {\n super(response, builder);\n }", "DeviceState createDeviceState();", "List<? extends IDeviceStat...
[ "0.7230747", "0.49293554", "0.4878525", "0.46710783", "0.4656989", "0.4654418", "0.4634253", "0.4493787", "0.4488934", "0.4472753", "0.44329163", "0.43181807", "0.4302653", "0.42896074", "0.42768818", "0.42576516", "0.42530838", "0.42280298", "0.41934517", "0.41917917", "0.41...
0.68372387
1
/llenar el adaptador con los datos del arreglo tipo JSON que regresa el servidor
@Override protected void onPostExecute(JSONArray jsonArray) { super.onPostExecute(jsonArray); //consultar los datos de la respuesta del servidor qu evienen en la variable //del parametro del metodo; el cual es del mismo tipo que el resultado del metodo //doinbckgroun //recorrer el jsonarray y consultar los nodos del json for (int i=0;i<jsonArray.length();i++){ Usuario usuario=new Usuario(); try { JSONObject jsonObject=jsonArray.getJSONObject(i); //usuario.setId(jsonObject.getInt("id")); usuario.setUser(jsonObject.getString("user")); usuario.setPass(jsonObject.getString("pass")); usuario.setName(jsonObject.getString("name")); usuario.setPhone(jsonObject.getString("phone")); usuario.setAddress(jsonObject.getString("address")); usuario.setQuestion(jsonObject.getString("question")); usuario.setAnswer(jsonObject.getString("answer")); SharedPreferences preferences = getSharedPreferences("Usuario", MODE_PRIVATE); SharedPreferences.Editor editor = preferences.edit(); editor.putString("id", idFinal); editor.putString("user", usuario.getUser()); editor.putString("pass", usuario.getPass()); editor.putString("name", usuario.getName()); editor.putString("phone", usuario.getPhone()); editor.putString("address", usuario.getAddress()); editor.putString("question", usuario.getQuestion()); editor.putString("answer",usuario.getAnswer()); editor.commit(); } catch (JSONException e) { e.printStackTrace(); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public List<EstadoCita> obtenerDatosJSON(String rta){\n Log.e(\"Agenda JSON\",rta);\n // La lista de generos a retornar\n List<EstadoCita> lista = new ArrayList<EstadoCita>();\n try{\n /**\n * accedemos al json como array, ya que estamos 10...
[ "0.6690387", "0.66423374", "0.6337987", "0.63254994", "0.62844706", "0.62764174", "0.62716013", "0.62685305", "0.62540203", "0.6235928", "0.62289286", "0.61794007", "0.61493623", "0.6144322", "0.6137844", "0.6114205", "0.6066107", "0.60438955", "0.60384274", "0.6037561", "0.6...
0.0
-1
TODO Autogenerated method stub Map, Long> oldByteMap=new ConcurrentHashMap(); Map, Long> newByteMap=new ConcurrentHashMap(); TODO Autogenerated method stub
@Override public void run() { while(isactive){ //读取每个接入交换机的table? long time1=System.currentTimeMillis(); for(Node node:nodes){ TableReader tableReader=new TableReader(); tableReader.setNode(node.getNode_id()); tableReader.setTableid(tableid); //读取每条流表的static信息 if(tableid=="5"){ try { for(String id:tableReader.read().keySet()){ //读取table中的每条流表 Flow flow=tableReader.read().get(id); //是否存在inport 匹配 MonTag monTag=new MonTag(); if(flow.getMatch()!=null && flow.getMatch().getEthernet_Match()!=null && flow.getMatch().getIn_port()!=null){ String in_port=flow.getMatch().getIn_port(); //将监控标签加入该port monTag.setInport(in_port); //是否存在源mac if(flow.getMatch().getEthernet_Match().getEthernet_source()!=null){ Ethernet_source source=flow.getMatch().getEthernet_Match().getEthernet_source(); monTag.setSrcmac(source.getAddress()); } //是否存在目的mac if(flow.getMatch().getEthernet_Match().getEthernet_destination()!=null){ Ethernet_destination destination=flow.getMatch().getEthernet_Match().getEthernet_destination(); monTag.setDestmac(destination.getAddress()); } //获取当前流表的数据 long nowbyte=flow.getFlow_Statistic().getByte_count(); long nowpkt=flow.getFlow_Statistic().getPacket_count(); NetStatic netStatic=new NetStatic(); //设置监控统计项 netStatic.setBytecount(nowbyte) .setPacketcount(nowpkt); //判断是否是第一次读取 if(netMonitorMap.get(monTag)!=null){ long oldbyte=netMonitorMap.get(monTag).getBytecount(); long oldpkt=netMonitorMap.get(monTag).getPacketcount(); if(nowbyte < oldbyte){ nowbyte=oldbyte+nowbyte; } //计算速度 long bytespeed=(nowbyte-oldbyte)/(3000/1000); long pktspeed=(nowpkt-oldpkt)/(3000/1000); netStatic.setPacketspeed(pktspeed).setBytespeed(bytespeed); } this.netMonitorMap.put(monTag, netStatic); } } } catch (TableReadException e) { // TODO Auto-generated catch block e.printStackTrace(); } } else if(tableid=="3") { // monTag.setNode(node.getNode_id()); try { for(String id:tableReader.read().keySet()){ MonTag monTag=new MonTag(); monTag.setNode(node.getNode_id()); NetStatic netStatic=new NetStatic(); Flow flow=tableReader.read().get(id); //流表是否存在inport匹配域 if(flow.getMatch().getIn_port()!=null){ String inport=flow.getMatch().getIn_port(); monTag.setInport(inport); } //流表是否存在protocol域 if(flow.getMatch().getIp_Match()!=null && flow.getMatch().getIp_Match().getIp_protocol()!=null){ String ipProtocol=flow.getMatch().getIp_Match().getIp_protocol(); Protocol_Type protocol_Type=Protocol_Type.Valueof(Integer.parseInt(ipProtocol)); monTag.setProtocol_Type(protocol_Type); } else { monTag.setProtocol_Type(Protocol_Type.UNKNOW); } //获取当前流表的数据 long nowbyte=flow.getFlow_Statistic().getByte_count(); long nowpkt=flow.getFlow_Statistic().getPacket_count(); netStatic.setBytecount(nowbyte) .setPacketcount(nowpkt); //判断是否是第一次读取 if(netMonitorMap.get(monTag)!=null){ long oldbyte=netMonitorMap.get(monTag).getBytecount(); long oldpkt=netMonitorMap.get(monTag).getPacketcount(); if(nowbyte < oldbyte){ nowbyte=oldbyte+nowbyte; } //计算速度 long bytespeed=(nowbyte-oldbyte)/(3000/1000); long pktspeed=(nowpkt-oldpkt)/(3000/1000); netStatic.setPacketspeed(pktspeed).setBytespeed(bytespeed); } //System.out.println("MonTag "+monTag.getInport()+"<<<>>>"+monTag.getProtocol_Type()); long bytespeed=netStatic.getBytespeed(); this.netMonitorMap.put(monTag, netStatic); //for(MonTag monTag1:netMonitorMap.keySet()){ // System.out.println("MonTag "+monTag1.getInport()+" "+monTag1.getProtocol_Type()); // } } } catch (NumberFormatException | TableReadException e) { // TODO Auto-generated catch block e.printStackTrace(); } } } long time2=System.currentTimeMillis(); interval=3000-(time2-time1); System.out.println("Monitoring"); try { Thread.sleep(interval); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void method_9396() {\r\n super();\r\n this.field_8914 = Maps.newConcurrentMap();\r\n }", "public ConcurrentHashMap<Long, NativeDownloadModel> mo45197b() {\n ConcurrentHashMap<Long, NativeDownloadModel> concurrentHashMap = new ConcurrentHashMap<>();\n try {\n for (Map.E...
[ "0.60988283", "0.6077354", "0.57535267", "0.559619", "0.54835063", "0.5340261", "0.5252422", "0.52379155", "0.5139082", "0.51174927", "0.5115084", "0.50942", "0.5035788", "0.49935243", "0.49899447", "0.49804306", "0.49804306", "0.4961983", "0.49231187", "0.49157915", "0.49125...
0.0
-1
interrupt the wait (kill this thread)
public void dispose() { interruptWait(AceSignalMessage.SIGNAL_TERM, "disposed"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void cancel() {\n\tsleepThread.interrupt();\n }", "public void interrupt();", "public void timerInterrupt() \n {\n\t\n Machine.interrupt().disable(); //disable\n\n //if waitingQueue is empty, and current time is greater than or equal to the first ThreadWaits, wakeUp time,\n while(!wa...
[ "0.74812794", "0.7117735", "0.71086884", "0.7066313", "0.7055005", "0.6987925", "0.69116104", "0.6864087", "0.6832283", "0.68127483", "0.6809533", "0.6790585", "0.67540354", "0.67211986", "0.6704439", "0.6680983", "0.66804147", "0.667979", "0.66434646", "0.66399944", "0.66383...
0.0
-1
Serializes and deserializes the specified object.
@SuppressWarnings("unchecked") static <T> T reserialize(T object) { checkNotNull(object); ByteArrayOutputStream bytes = new ByteArrayOutputStream(); try { ObjectOutputStream out = new ObjectOutputStream(bytes); out.writeObject(object); ObjectInputStream in = new ObjectInputStream(new ByteArrayInputStream(bytes.toByteArray())); return (T) in.readObject(); } catch (IOException | ClassNotFoundException e) { throw new RuntimeException(e); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void serialize(Object obj, OutputStream stream) throws IOException;", "public abstract Object deserialize(Object object);", "public abstract void serialize(OutputStream stream, T object) throws IOException;", "private void serializeObject(final Object object, final StringBuffer buffer)\n {\n serial...
[ "0.7237786", "0.6892062", "0.67329437", "0.6679516", "0.6578926", "0.6498536", "0.642824", "0.6409637", "0.63216645", "0.6298425", "0.6296595", "0.627854", "0.6234316", "0.6192209", "0.61456835", "0.6099016", "0.60935235", "0.60628664", "0.6062135", "0.60549706", "0.60519254"...
0.61759865
14
Valida que haya una opcion seleccionada Obtiene la especialidad seleccionada Muestra todos los especialistas de esa especialidad
public void verEspecialistas(HttpServletRequest request, HttpServletResponse response) throws ServletException { try { int codEspecialidad = Integer.parseInt(request.getParameter("opcionesEspecid")); CtrlSolicitarTurno controlador = new CtrlSolicitarTurno(); Especialidad e = controlador.getOneEspecialidad(codEspecialidad); if(e == null) servlet.ErrorPaciente("SolicitarTurno","No se ha podido recuperar la especialidad", response); request.setAttribute("camino","especialista"); ArrayList<Especialista> especs = controlador.getAllEspecialistas(e); request.setAttribute("ListaEspecialistas", especs); //Si la coleccion esta vacia significa que no existen especialistas con esa especialidad if(especs.size() == 0) request.setAttribute("Especialidad", e.getNombre()); opMenuSolicitarTurno(request, response); }catch(NumberFormatException | ServletException ne) { servlet.ErrorPaciente("SolicitarTurno","Por favor seleccione una opcion.", response); } catch (SQLException e1) { servlet.ErrorPaciente("SolicitarTurno","Ha ocurrido un error al intentar recuperar los especialistas. Causa: "+e1.getMessage(), response); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n\tpublic void testLecturaSelect(){\n\t\tassertEquals(esquemaEsperado.getExpresionesSelect().toString(), esquemaReal.getExpresionesSelect().toString());\n\t}", "public void ejercicio01() {\r\n\t\tcabecera(\"01\",\"Seleccion de opciones\");\r\n\r\n\t\tRectangulo rectangulo=new Rectangulo(10,5);\r\n\t\tSyste...
[ "0.69125515", "0.6667335", "0.66078657", "0.6541046", "0.65318394", "0.65126294", "0.6342921", "0.62980044", "0.6279631", "0.6270364", "0.6239963", "0.6234559", "0.6232078", "0.62208825", "0.6206975", "0.62067914", "0.6194468", "0.6189853", "0.616327", "0.61504585", "0.610593...
0.0
-1
Try to fetch DecorView from context
protected ViewGroup getDecorView() { if (getContext() instanceof Activity) { View decor = ((Activity) getContext()).getWindow().getDecorView(); if (decor instanceof ViewGroup) { return (ViewGroup) decor; } } //Try to fetch DecorView from parents ViewGroup view = this; while (view.getParent() != null && view.getParent() instanceof ViewGroup) { view = (ViewGroup) view.getParent(); } return view; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected ReliedOnView() {}", "public abstract String getDecoratorInfo();", "public interface IView {\n Context getContexts();\n}", "protected View getDecorContent() {\n return mDecorContent;\n }", "protected View getCompartmentView() {\n\t\tView view = (View) getDecoratorTarget().getAdapter(V...
[ "0.58485734", "0.5795212", "0.5579225", "0.55421895", "0.53806925", "0.52465546", "0.5197007", "0.51701975", "0.51669824", "0.50092506", "0.5008072", "0.50069696", "0.4954707", "0.49212372", "0.48645836", "0.48618102", "0.4831215", "0.48159325", "0.4766189", "0.47585076", "0....
0.5511556
4
TODO reset password link and set new password
@Override public void onClick(View v) { getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN); setContentView(R.layout.activity_fragment); Utils.replaceFragment(LoginActivity.this, new ResetPswFragment(), R.id.fragment_container, false); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void setPassword(Password newPassword, String plainPassword) throws NoUserSelectedException;", "public void setPassword(java.lang.String newPassword);", "public void login_pw() {\n\t\tIntent intent = new Intent(this, ResetPasswordActivity.class);\n\t\tstartActivity(intent);\n\t}", "public void setPassword(St...
[ "0.7669307", "0.7587776", "0.7566884", "0.74243516", "0.7336046", "0.73042566", "0.73042566", "0.73042566", "0.7295603", "0.7201337", "0.7183926", "0.7172314", "0.71217066", "0.7100184", "0.7085455", "0.70790166", "0.70706856", "0.70377684", "0.7036659", "0.7033667", "0.70316...
0.0
-1
Shows the progress UI and hides the login form.
@TargetApi(Build.VERSION_CODES.HONEYCOMB_MR2) private void showProgress(final boolean show) { // On Honeycomb MR2 we have the ViewPropertyAnimator APIs, which allow // for very easy animations. If available, use these APIs to fade-in // the progress spinner. if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB_MR2) { int shortAnimTime = getResources().getInteger(android.R.integer.config_shortAnimTime); mLoginFormView.setVisibility(show ? View.GONE : View.VISIBLE); mLoginFormView.animate().setDuration(shortAnimTime).alpha( show ? 0 : 1).setListener(new AnimatorListenerAdapter() { @Override public void onAnimationEnd(Animator animation) { mLoginFormView.setVisibility(show ? View.GONE : View.VISIBLE); } }); mProgressView.setVisibility(show ? View.VISIBLE : View.GONE); mProgressView.animate().setDuration(shortAnimTime).alpha( show ? 1 : 0).setListener(new AnimatorListenerAdapter() { @Override public void onAnimationEnd(Animator animation) { mProgressView.setVisibility(show ? View.VISIBLE : View.GONE); } }); } else { // The ViewPropertyAnimator APIs are not available, so simply show // and hide the relevant UI components. mProgressView.setVisibility(show ? View.VISIBLE : View.GONE); mLoginFormView.setVisibility(show ? View.GONE : View.VISIBLE); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override public void showLoginForm() {\n LoginViewState vs = (LoginViewState) viewState;\n vs.setShowLoginForm();\n\n errorView.setVisibility(View.GONE);\n\n setFormEnabled(true);\n //loginButton.setLoading(false);\n }", "private void displayProgressDialog() {\n pDia...
[ "0.7621026", "0.74284565", "0.73967826", "0.7286585", "0.72790235", "0.72643507", "0.72605824", "0.72436935", "0.7186172", "0.7047085", "0.69236714", "0.6893757", "0.6891113", "0.6866205", "0.68238723", "0.67860216", "0.67708963", "0.6761273", "0.67412", "0.6739837", "0.67131...
0.6713914
43
Create adapter to tell the AutoCompleteTextView what to show in its dropdown list.
private void addEmailsToAutoComplete(List<String> emailAddressCollection) { ArrayAdapter<String> adapter = new ArrayAdapter<>(LoginActivity.this, android.R.layout.simple_dropdown_item_1line, emailAddressCollection); mEmailView.setAdapter(adapter); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void setupAutoComplete() {\n // Map between AutoCompleteTextViews and their Adapters. Some text fields have a custom\n // adapter whose data is updated dynamically (rather than being statically set)\n Map<AutoCompleteTextView, ArrayAdapter<String>> map = new HashMap<>();\n map.p...
[ "0.69251245", "0.6781905", "0.67093617", "0.6673698", "0.66282773", "0.6547743", "0.6547292", "0.6534585", "0.65123296", "0.6370756", "0.63326705", "0.62794495", "0.6175075", "0.615167", "0.61018836", "0.6059119", "0.6048769", "0.60367614", "0.5974004", "0.592761", "0.5897378...
0.0
-1
AWS access key id.
@Config("aws_access_key_id") @ConfigDefault("null") Optional<String> getAwsAccessKeyId();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getAccessKeyId();", "String getEncryptionKeyId();", "public String getAccessKeyId() {\n return accessKeyId;\n }", "public String accessKey() {\n return this.accessKey;\n }", "public String getAccessKey() {\n return cred.getAWSAccessKeyId();\n }", "java.lang.Str...
[ "0.7405616", "0.7045022", "0.7041723", "0.6760649", "0.66479105", "0.65154696", "0.64134544", "0.6399307", "0.6397495", "0.63401115", "0.6335716", "0.63112396", "0.62374294", "0.6177907", "0.6174383", "0.6123491", "0.6111451", "0.6089966", "0.6060635", "0.603625", "0.603625",...
0.67287713
4
AWS secret access key
@Config("aws_secret_access_key") @ConfigDefault("null") Optional<String> getAwsSecretAccessKey();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getAccessKeySecret() {\n return accessKeySecret;\n }", "public void setAccessKeySecret(String accessKeySecret) {\n this.accessKeySecret = accessKeySecret;\n }", "public String getSecretAccessKey() {\n return cred.getAWSSecretKey();\n }", "private String key() {\n ...
[ "0.74446046", "0.70984125", "0.70664716", "0.7028117", "0.69857687", "0.69225633", "0.687841", "0.66917527", "0.6674462", "0.6534777", "0.6527236", "0.648417", "0.6473513", "0.64265", "0.6405958", "0.63160056", "0.6279207", "0.62555736", "0.6253052", "0.62012297", "0.61643565...
0.6754696
7
Created by Yordin Alayn on 29.11.15.
public interface NegotiationTransmission { /** * The method <code>getTransmissionId</code> returns the transmission id of the negotiation transmission * @return an UUID the transmission id of the negotiation transmission */ UUID getTransmissionId(); /** * The method <code>getTransactionId</code> returns the transaction id of the negotiation transmission * @return an UUID the transaction id of the negotiation transmission */ UUID getTransactionId(); /** * The method <code>getNegotiationId</code> returns the negotiation id of the negotiation transmission * @return an UUID the negotiation id of the negotiation */ UUID getNegotiationId(); /** * The method <code>getNegotiationTransactionType</code> returns the transaction type of the negotiation transmission * @return an NegotiationTransactionType of the transaction type */ NegotiationTransactionType getNegotiationTransactionType(); /** * The method <code>getPublicKeyActorSend</code> returns the public key the actor send of the negotiation transaction * @return an String the public key of the actor send */ String getPublicKeyActorSend(); /** * The method <code>getActorSendType</code> returns the actor send type of the negotiation transmission * @return an PlatformComponentType of the actor send type */ PlatformComponentType getActorSendType(); /** * The method <code>getPublicKeyActorReceive</code> returns the public key the actor receive of the negotiation transmission * @return an String the public key of the actor receive */ String getPublicKeyActorReceive(); /** * The method <code>getActorReceiveType</code> returns the actor receive type of the negotiation transmission * @return an PlatformComponentType of the actor receive type */ PlatformComponentType getActorReceiveType(); /** * The method <code>getTransmissionType</code> returns the type of the negotiation transmission * @return an NegotiationTransmissionType of the negotiation type */ NegotiationTransmissionType getTransmissionType(); /** * The method <code>getTransmissionState</code> returns the state of the negotiation transmission * @return an NegotiationTransmissionStateof the negotiation state */ NegotiationTransmissionState getTransmissionState(); /** * The method <code>getNegotiationXML</code> returns the xml of the negotiation relationship with negotiation transmission * @return an NegotiationType the negotiation type of negotiation */ NegotiationType getNegotiationType(); void setNegotiationType(NegotiationType negotiationType); /** * The method <code>getNegotiationXML</code> returns the xml of the negotiation relationship with negotiation transmission * @return an String the xml of negotiation */ String getNegotiationXML(); /** * The method <code>getTimestamp</code> returns the time stamp of the negotiation transmission * @return an Long the time stamp of the negotiation transmission */ long getTimestamp(); /** * The method <code>isPendingToRead</code> returns if this pending to read the negotiation transmission * @return an boolean if this pending to read */ boolean isPendingToRead(); /** * The method <code>confirmRead</code> confirm the read of the negotiation trasmission */ void confirmRead(); /** * The method <code>setNegotiationTransactionType</code> set the negotiation transaction type */ void setNegotiationTransactionType(NegotiationTransactionType negotiationTransactionType); /** * The method <code>setTransmissionType</code> set the Transmission Type */ void setTransmissionType(NegotiationTransmissionType negotiationTransmissionType); /** * The method <code>setTransmissionState</code> set the Transmission State */ void setTransmissionState(NegotiationTransmissionState negotiationTransmissionState); public boolean isFlagRead(); public void setFlagRead(boolean flagRead); public int getSentCount(); public void setSentCount(int sentCount); public UUID getResponseToNotificationId(); public void setResponseToNotificationId(UUID responseToNotificationId); public boolean isPendingFlag(); public void setPendingFlag(boolean pendingFlag); public String toJson(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "private stendhal() {\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "public fina...
[ "0.5937666", "0.59281135", "0.5798834", "0.5713502", "0.5713502", "0.57057196", "0.5678998", "0.56510615", "0.5640679", "0.5636195", "0.5619033", "0.5596673", "0.5595758", "0.55935836", "0.5587245", "0.5574986", "0.5549855", "0.5536199", "0.55238193", "0.55173934", "0.5517182...
0.0
-1
The method getTransmissionId returns the transmission id of the negotiation transmission
UUID getTransmissionId();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Transmission getTransmission(Long transmissionId);", "NegotiationTransmissionType getTransmissionType();", "UUID getNegotiationId();", "public Transmission getTransmission() {\n return transmission;\n }", "java.lang.String getTxId();", "public int getId() {\n return txId;\n }", "pub...
[ "0.7521881", "0.6898216", "0.68036085", "0.6533122", "0.64288485", "0.63891405", "0.6320048", "0.6314868", "0.6202902", "0.6153059", "0.6152449", "0.6113023", "0.6033007", "0.60176593", "0.60130084", "0.60113406", "0.5972358", "0.596768", "0.59656173", "0.5921125", "0.5896201...
0.8169662
0
The method getTransactionId returns the transaction id of the negotiation transmission
UUID getTransactionId();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getTransactionId() {\n return transactionId;\n }", "public String getTransactionId() {\n return transactionId;\n }", "public String getTransactionId()\n\t{\n\t\treturn transactionId;\n\t}", "public java.lang.String getTransactionId() {\n return transactionId;\n }", "pu...
[ "0.80248404", "0.80248404", "0.80174494", "0.799945", "0.799945", "0.7994907", "0.7993532", "0.799036", "0.7960907", "0.7960907", "0.7959991", "0.7959991", "0.7945301", "0.7928705", "0.7852954", "0.7852954", "0.78195643", "0.7812266", "0.7789833", "0.77790725", "0.77204025", ...
0.80262846
0
The method getNegotiationId returns the negotiation id of the negotiation transmission
UUID getNegotiationId();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "NegotiationType getNegotiationType();", "NegotiationTransactionType getNegotiationTransactionType();", "java.lang.String getProtocolId();", "public String getProtocolId();", "public final String getNetId( )\r\n {\r\n return netId;\r\n }", "String getNegotiationXML();", "java.lang.String getRecogni...
[ "0.65899336", "0.6324873", "0.6197084", "0.59621876", "0.58900595", "0.5883157", "0.58128715", "0.5756192", "0.56856066", "0.563515", "0.56148106", "0.55858225", "0.5583198", "0.5556241", "0.5535368", "0.5535368", "0.549747", "0.54914397", "0.5490098", "0.5482308", "0.5451754...
0.851634
0
The method getNegotiationTransactionType returns the transaction type of the negotiation transmission
NegotiationTransactionType getNegotiationTransactionType();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void setNegotiationTransactionType(NegotiationTransactionType negotiationTransactionType);", "NegotiationTransmissionType getTransmissionType();", "NegotiationType getNegotiationType();", "void setTransmissionType(NegotiationTransmissionType negotiationTransmissionType);", "public String getProposedTransac...
[ "0.80420125", "0.7877524", "0.77795434", "0.6944778", "0.6869104", "0.67857414", "0.6288129", "0.59603155", "0.5762758", "0.57048416", "0.5672214", "0.56592613", "0.5644572", "0.56318676", "0.55823064", "0.557986", "0.55784214", "0.5577962", "0.5554928", "0.5472854", "0.54441...
0.9203282
0
The method getPublicKeyActorSend returns the public key the actor send of the negotiation transaction
String getPublicKeyActorSend();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "String getPublicKeyActorReceive();", "public PublicKey getPublicKey() {\n return publicKey;\n }", "public PublicKey getPublicKey(){\n\t\treturn this.publickey;\n\t}", "public PublicKey getPublicKey() {\r\n return publicKey;\r\n }", "public PublicKey getPublicKey() {\n return pk;\n ...
[ "0.80893326", "0.6509852", "0.65077186", "0.6490467", "0.6481273", "0.6409563", "0.6387173", "0.634069", "0.6326179", "0.6300077", "0.62895465", "0.61209136", "0.6117383", "0.60869527", "0.6034581", "0.58816504", "0.5820638", "0.5753342", "0.57202363", "0.56915754", "0.561187...
0.8788465
0
The method getActorSendType returns the actor send type of the negotiation transmission
PlatformComponentType getActorSendType();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "PlatformComponentType getActorReceiveType();", "String getActorType();", "public final ActorType getType() {\n return type;\n }", "NegotiationTransmissionType getTransmissionType();", "public Boolean getSendType() {\n return sendType;\n }", "TransmissionProtocol.Type getType();", "p...
[ "0.73676187", "0.68772", "0.6801485", "0.6635326", "0.6437365", "0.63558483", "0.6321358", "0.61781687", "0.61556345", "0.60968906", "0.60809904", "0.59625566", "0.59327537", "0.58898354", "0.5814865", "0.57873684", "0.57410073", "0.5737346", "0.5727813", "0.57039756", "0.569...
0.838367
0
The method getPublicKeyActorReceive returns the public key the actor receive of the negotiation transmission
String getPublicKeyActorReceive();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "String getPublicKeyActorSend();", "OctetString getPublicKey();", "public String getPublicKey();", "public PublicKey getPublicKey() {\n return publicKey;\n }", "public PublicKey getPublicKey() {\n return pk;\n }", "public PublicKey getPublicKey() {\r\n return publicKey;\r\n }", ...
[ "0.8152904", "0.6074288", "0.60628206", "0.6055289", "0.6039479", "0.60338956", "0.6003901", "0.59372276", "0.5921882", "0.5888652", "0.5874502", "0.58261955", "0.58182317", "0.55757535", "0.555904", "0.5546095", "0.5536238", "0.5508859", "0.5500672", "0.545305", "0.5393497",...
0.8810139
0
The method getActorReceiveType returns the actor receive type of the negotiation transmission
PlatformComponentType getActorReceiveType();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public java.lang.String getReceiveType () {\n\t\treturn receiveType;\n\t}", "PlatformComponentType getActorSendType();", "public final ActorType getType() {\n return type;\n }", "String getActorType();", "public ActorType getActorType() {\n return ActorDao.getActorTypeByRefId(getActorTypeR...
[ "0.7412349", "0.7185809", "0.7138431", "0.7035225", "0.6708562", "0.63717103", "0.6349242", "0.628993", "0.62520355", "0.60542065", "0.60507137", "0.6045657", "0.6045657", "0.60396993", "0.594954", "0.59329456", "0.59315187", "0.59299165", "0.5925522", "0.59142864", "0.588859...
0.83070785
0
The method getTransmissionType returns the type of the negotiation transmission
NegotiationTransmissionType getTransmissionType();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "TransmissionProtocol.Type getType();", "void setTransmissionType(NegotiationTransmissionType negotiationTransmissionType);", "NegotiationTransmissionState getTransmissionState();", "public TransmissionProtocol.Type getType() {\n @SuppressWarnings(\"deprecation\")\n TransmissionProtocol.Type res...
[ "0.81099635", "0.7784961", "0.725671", "0.7155018", "0.71400875", "0.7065016", "0.6990406", "0.6770984", "0.65170795", "0.63940454", "0.6392178", "0.6388294", "0.6344591", "0.63322175", "0.6319038", "0.6310594", "0.6265612", "0.6176075", "0.6146017", "0.60986465", "0.60855365...
0.9372869
0
The method getTransmissionState returns the state of the negotiation transmission
NegotiationTransmissionState getTransmissionState();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void setTransmissionState(NegotiationTransmissionState negotiationTransmissionState);", "NegotiationTransmissionType getTransmissionType();", "public SimulationState getState() {\n\t\treturn state;\n\t}", "public java.lang.String getSenderState() {\r\n return senderState;\r\n }", "public String g...
[ "0.7045935", "0.7000938", "0.64398926", "0.63858503", "0.63739717", "0.6370873", "0.63699883", "0.6357185", "0.6348896", "0.6348749", "0.6348118", "0.6348118", "0.6348118", "0.6337273", "0.6337273", "0.6317692", "0.6287369", "0.62871116", "0.6285377", "0.62849116", "0.6284911...
0.93357223
0
The method getNegotiationXML returns the xml of the negotiation relationship with negotiation transmission
NegotiationType getNegotiationType();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "String getNegotiationXML();", "NegotiationTransactionType getNegotiationTransactionType();", "UUID getNegotiationId();", "void setNegotiationTransactionType(NegotiationTransactionType negotiationTransactionType);", "public String getXml() {\n\t\treturn _xml;\n\t}", "public String getXml() {\n retu...
[ "0.87761533", "0.6617143", "0.6098705", "0.5725141", "0.5632804", "0.56221265", "0.55979466", "0.55971915", "0.5545449", "0.54675275", "0.5426851", "0.5364727", "0.53236973", "0.52435666", "0.5227032", "0.52227175", "0.52112585", "0.52112585", "0.52089494", "0.51837397", "0.5...
0.67327994
1
The method getNegotiationXML returns the xml of the negotiation relationship with negotiation transmission
String getNegotiationXML();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "NegotiationType getNegotiationType();", "NegotiationTransactionType getNegotiationTransactionType();", "UUID getNegotiationId();", "void setNegotiationTransactionType(NegotiationTransactionType negotiationTransactionType);", "public String getXml() {\n\t\treturn _xml;\n\t}", "public String getXml() {\n ...
[ "0.67332524", "0.66169083", "0.6098371", "0.5724483", "0.56323516", "0.5621743", "0.55976003", "0.5596953", "0.5545375", "0.5467979", "0.54270285", "0.5363728", "0.5323125", "0.5242907", "0.5226597", "0.5222753", "0.5211727", "0.5211727", "0.5208853", "0.5184233", "0.5181683"...
0.877638
0
The method getTimestamp returns the time stamp of the negotiation transmission
long getTimestamp();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "java.lang.String getTimestamp();", "java.lang.String getTimestamp();", "String getTimestamp();", "String getTimestamp();", "com.google.protobuf.Timestamp getSendTime();", "com.google.protobuf.Timestamp getTimestamp();", "int getTimestamp();", "public long getTimestamp();", "public long getTimestamp...
[ "0.77745515", "0.77745515", "0.7727646", "0.7727646", "0.76840174", "0.7672485", "0.75165284", "0.74543726", "0.74543726", "0.74232024", "0.74130434", "0.7391259", "0.7381914", "0.7381914", "0.7377781", "0.7373205", "0.7373205", "0.735007", "0.7343799", "0.7326703", "0.730512...
0.74249834
23
The method isPendingToRead returns if this pending to read the negotiation transmission
boolean isPendingToRead();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "boolean hasSendReading();", "public boolean ready() {\n try {\n return in.available() > 0;\n } catch (IOException x) {\n return false;\n }\n }", "boolean hasRead();", "@Override\n public boolean messagePending() {\n return commReceiver.messagePending();...
[ "0.685387", "0.6336748", "0.62995785", "0.6236992", "0.6230192", "0.6197038", "0.61866623", "0.6181602", "0.614188", "0.6128932", "0.6098332", "0.6092585", "0.60844076", "0.6078246", "0.6074624", "0.6073376", "0.6061162", "0.605362", "0.6042166", "0.60296535", "0.6029271", ...
0.77975
0
The method confirmRead confirm the read of the negotiation trasmission
void confirmRead();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "boolean getRead();", "public void read() {\n\t\tthis.isRead = true;\n\t}", "boolean getForRead();", "public void setRead(){\n \tthis.isRead = true;\n }", "boolean hasForRead();", "public boolean isRead(){\n \treturn isRead;\n }", "public boolean sendReadMessage() {\n return sendReadM...
[ "0.6177747", "0.614446", "0.6067957", "0.6058008", "0.5990929", "0.5939082", "0.59386903", "0.59271383", "0.5925052", "0.59117955", "0.5901159", "0.58891624", "0.5876233", "0.5845127", "0.5828508", "0.5800502", "0.57937276", "0.57781106", "0.5777769", "0.57538474", "0.5741541...
0.794838
0
The method setNegotiationTransactionType set the negotiation transaction type
void setNegotiationTransactionType(NegotiationTransactionType negotiationTransactionType);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "NegotiationTransactionType getNegotiationTransactionType();", "void setTransmissionType(NegotiationTransmissionType negotiationTransmissionType);", "void setTransmissionState(NegotiationTransmissionState negotiationTransmissionState);", "NegotiationType getNegotiationType();", "NegotiationTransmissionType ...
[ "0.80145377", "0.7898779", "0.66388804", "0.64766914", "0.64028007", "0.62245464", "0.58359295", "0.56902856", "0.5682185", "0.5668426", "0.55851877", "0.5569384", "0.5429571", "0.5269943", "0.51575553", "0.51564974", "0.51415724", "0.5106482", "0.50683856", "0.5033228", "0.4...
0.91185796
0
The method setTransmissionType set the Transmission Type
void setTransmissionType(NegotiationTransmissionType negotiationTransmissionType);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setTransmission(Transmission transmission) {\n this.transmission = transmission;\n }", "NegotiationTransmissionType getTransmissionType();", "public void setSettlementType(java.lang.String settlementType) {\n this.settlementType = settlementType;\n }", "public Builder setType(...
[ "0.706624", "0.7010819", "0.68779844", "0.672158", "0.65827996", "0.65612316", "0.6361409", "0.6349987", "0.63000107", "0.62923664", "0.6267324", "0.62577474", "0.6240383", "0.6236344", "0.622891", "0.6214967", "0.6214967", "0.6214967", "0.6206445", "0.62046736", "0.62031555"...
0.7745856
0
The method setTransmissionState set the Transmission State
void setTransmissionState(NegotiationTransmissionState negotiationTransmissionState);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void SetState(VehicleState state) {\n this.state = state;\n }", "NegotiationTransmissionState getTransmissionState();", "public void setTransmission(Transmission transmission) {\n this.transmission = transmission;\n }", "void setState(SimulationState state) {\n\t\tthis.state = sta...
[ "0.70533216", "0.66798514", "0.6674608", "0.65906817", "0.65820366", "0.65573764", "0.6402038", "0.6402038", "0.63611686", "0.62458986", "0.620708", "0.61706245", "0.6155224", "0.6143213", "0.61409855", "0.61347115", "0.6099602", "0.6094066", "0.6087399", "0.6070683", "0.6061...
0.7408269
0
super.onItemClick(view, position, content, message);
@Override public void onItemClick(View view, int position, LocationMessage content, UIMessage message) { Intent intent = new Intent(view.getContext(), ShowTencentMap.class); intent.putExtra("location", message.getContent()); view.getContext().startActivity(intent); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void OnItemClick(int position) {\n }", "@Override\n public void itemClick(int pos) {\n }", "@Override\n public void onItemClick(int pos) {\n }", "@Override\n public void onItemClick(View view, int position){\n }", "@Override...
[ "0.86931425", "0.84387946", "0.8427055", "0.8260898", "0.82184213", "0.82184213", "0.8169098", "0.8108793", "0.8104156", "0.81008035", "0.8097396", "0.8097396", "0.8094334", "0.80909467", "0.80862844", "0.80862844", "0.80862844", "0.8072602", "0.8068262", "0.80425906", "0.803...
0.0
-1
TODO Autogenerated method stub
public static boolean linearSearch(int[] arr, int num) { if(arr==null || arr.length==0){ return false; } int len= arr.length; for (int i = 0; i < len; i++) { if(arr[i]==num){ return true; } } return false; }
{ "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
TODO Autogenerated method stub
public static void main(String[] args) { int[] arr = {2,7,4,9,36,3,0,24,65,6}; System.out.println("Enter number to be searched:\n"); Scanner scanner = new Scanner(System.in); int num = scanner.nextInt(); System.out.println("Number is "+num); if(linearSearch(arr,num)){ System.out.println("Number is present"); } else{ System.out.println("Number is not present"); } }
{ "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
Sets the icon and title of a drawer in the navigation drawer.
@Override public void onBindViewHolder(DrawerAdapter.DrawerViewHolder holder, int position) { Drawer currentDrawer = drawerInfo.get(position); holder.title.setText(currentDrawer.getTitle()); holder.icon.setImageResource(currentDrawer.getIconId()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void onDrawerOpened(View drawerView) {\n super.onDrawerOpened(drawerView);\n// getActionBar().setTitle(mDrawerTitle);\n }", "public void onDrawerOpened(View drawerView) {\n super.onDrawerOpened(drawerView);\n// getActionBar().setTitle(...
[ "0.72061557", "0.72061557", "0.71395123", "0.7066885", "0.6997805", "0.699274", "0.6954385", "0.694481", "0.6889912", "0.6889912", "0.6880158", "0.6869872", "0.68336993", "0.6820865", "0.6784858", "0.67847836", "0.67812246", "0.67797154", "0.6778821", "0.6775142", "0.6769376"...
0.0
-1
Used for passing the list of options to the drawer, because of Android Annotations.
public void setDrawers(List<Drawer> drawers){ this.drawerInfo = drawers; this.notifyDataSetChanged(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void addDrawerItems(String[] optsArray) {\n final ArrayAdapter<String> mAdapter = new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, optsArray);\n mDrawerList.setAdapter(mAdapter);\n }", "public void viewOptions()\r\n {\r\n SetupScreen setupScreen = new SetupSc...
[ "0.6553625", "0.6341728", "0.627032", "0.61646247", "0.61523485", "0.6090882", "0.6074188", "0.60707426", "0.606392", "0.60273033", "0.60150194", "0.59361863", "0.5920015", "0.59158903", "0.58985394", "0.58931816", "0.5890995", "0.5857488", "0.58573955", "0.58305687", "0.5813...
0.0
-1
Creates new form NewJFrame
public NewJFrame() { this.setIconImage(img.getImage()); initComponents(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public NewJFrame() {\n Connect();\n initComponents();\n }", "public NewJFrame() {\n initComponents();\n \n }", "public NewJFrame() {\n initComponents();\n }", "public NewJFrame() {\n initComponents();\n }", "public NewJFrame() {\n initComponents...
[ "0.796484", "0.7945892", "0.7931828", "0.7931828", "0.7931828", "0.7931828", "0.7931828", "0.7931828", "0.7931828", "0.79161865", "0.78647804", "0.7763172", "0.76817715", "0.7648401", "0.75705475", "0.7474783", "0.7441117", "0.7441071", "0.7381736", "0.7241864", "0.7152069", ...
0.70620316
23
This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor.
@SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { jFileChooser1 = new javax.swing.JFileChooser(); jScrollPane1 = new javax.swing.JScrollPane(); textArea = new javax.swing.JTextArea(); menuBar = new javax.swing.JMenuBar(); fileMenu = new javax.swing.JMenu(); newFile = new javax.swing.JMenuItem(); saveFile = new javax.swing.JMenuItem(); editMenu = new javax.swing.JMenu(); fixFile = new javax.swing.JMenuItem(); changeWrongs = new javax.swing.JMenuItem(); deleteLastLetter = new javax.swing.JMenuItem(); jMenu1 = new javax.swing.JMenu(); darkMode = new javax.swing.JMenuItem(); lightMode = new javax.swing.JMenuItem(); defaultTheme = new javax.swing.JMenuItem(); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); setTitle("Text Editor"); setMinimumSize(new java.awt.Dimension(300, 100)); textArea.setBackground(new java.awt.Color(0, 51, 102)); textArea.setColumns(20); textArea.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N textArea.setForeground(new java.awt.Color(255, 255, 255)); textArea.setLineWrap(true); textArea.setRows(5); textArea.setWrapStyleWord(true); textArea.setMinimumSize(new java.awt.Dimension(75, 10)); jScrollPane1.setViewportView(textArea); menuBar.setBackground(new java.awt.Color(153, 153, 153)); menuBar.setBorder(null); fileMenu.setForeground(new java.awt.Color(0, 204, 204)); fileMenu.setText("Dosya"); fileMenu.setFont(new java.awt.Font("Segoe UI", 1, 12)); // NOI18N fileMenu.setMinimumSize(new java.awt.Dimension(50, 19)); fileMenu.setPreferredSize(new java.awt.Dimension(50, 19)); newFile.setForeground(new java.awt.Color(0, 204, 204)); newFile.setText("Dosya Aç"); newFile.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { newFileActionPerformed(evt); } }); fileMenu.add(newFile); saveFile.setBackground(new java.awt.Color(255, 255, 255)); saveFile.setForeground(new java.awt.Color(0, 204, 204)); saveFile.setText("Dosyayı Kaydet"); saveFile.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { saveFileActionPerformed(evt); } }); fileMenu.add(saveFile); menuBar.add(fileMenu); editMenu.setForeground(new java.awt.Color(0, 204, 204)); editMenu.setText("Düzenle"); editMenu.setFont(new java.awt.Font("Segoe UI", 1, 12)); // NOI18N editMenu.setMaximumSize(new java.awt.Dimension(60, 32767)); editMenu.setMinimumSize(new java.awt.Dimension(60, 19)); editMenu.setPreferredSize(new java.awt.Dimension(50, 19)); fixFile.setForeground(new java.awt.Color(0, 204, 204)); fixFile.setText("Hataları Düzelt"); fixFile.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { fixFileActionPerformed(evt); } }); editMenu.add(fixFile); changeWrongs.setForeground(new java.awt.Color(0, 204, 204)); changeWrongs.setText("Kelime Değiştir"); changeWrongs.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { changeWrongsActionPerformed(evt); } }); editMenu.add(changeWrongs); deleteLastLetter.setForeground(new java.awt.Color(0, 204, 204)); deleteLastLetter.setText("Son Harf Sil"); deleteLastLetter.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { deleteLastLetterActionPerformed(evt); } }); editMenu.add(deleteLastLetter); menuBar.add(editMenu); jMenu1.setForeground(new java.awt.Color(0, 204, 204)); jMenu1.setText("Tema Seç"); jMenu1.setFont(new java.awt.Font("Segoe UI", 1, 12)); // NOI18N darkMode.setForeground(new java.awt.Color(0, 204, 204)); darkMode.setText("Karanlık"); darkMode.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { darkModeActionPerformed(evt); } }); jMenu1.add(darkMode); lightMode.setForeground(new java.awt.Color(0, 204, 204)); lightMode.setText("Aydınlık"); lightMode.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { lightModeActionPerformed(evt); } }); jMenu1.add(lightMode); defaultTheme.setForeground(new java.awt.Color(0, 204, 204)); defaultTheme.setText("İlk Haline Dön"); defaultTheme.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { defaultThemeActionPerformed(evt); } }); jMenu1.add(defaultTheme); menuBar.add(jMenu1); setJMenuBar(menuBar); javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); getContentPane().setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 524, Short.MAX_VALUE) ); layout.setVerticalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 329, Short.MAX_VALUE) ); pack(); setLocationRelativeTo(null); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Form() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public frmRectangulo() {\n initComponents();\n }", "public form() {\n ...
[ "0.73201853", "0.7291607", "0.7291607", "0.7291607", "0.7285772", "0.7248832", "0.721371", "0.72083634", "0.71965843", "0.7190274", "0.71847606", "0.71592176", "0.71481156", "0.70935035", "0.70799935", "0.70570904", "0.6987588", "0.6977819", "0.69557554", "0.6953564", "0.6945...
0.0
-1
Criteria Query needs 5 steps: / 1. Use criteria builder to create Criteria Query returning the expected result object 2. Define roots for tables which are involved in the query 3. Define Predicates etc using criteria query 4. Add predicates etc to the criteria query 5. Build the TypedQuery using the entity manager and criteria query
@Test public void basic_select() { // 1). Use criteria builder to create criteria query returning expected // result object CriteriaBuilder criteriaBuilder = em.getCriteriaBuilder(); CriteriaQuery<Course> criteriaQuery = criteriaBuilder .createQuery(Course.class); // 2). Define roots for the tables which are involved in query Root<Course> root = criteriaQuery.from(Course.class); // 3. Define Predicates etc using criteria query // 4. Add predicates etc to the criteria query // Build Typerd Query TypedQuery<Course> query = em.createQuery(criteriaQuery.select(root)); List<Course> resultList = query.getResultList(); logger.info("Simple Criteria Query Result ===> {}", resultList); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic <T> TypedQuery<T> createQuery(CriteriaQuery<T> criteriaQuery) {\n\t\treturn null;\n\t}", "public Query<T, R> build() {\n // if criteria.size == 0, rootCriterion = null\n Criterion rootCriterion = null;\n if (criteria.size() == 1) {\n rootCriterion = criteria.ge...
[ "0.6382253", "0.6355779", "0.62788975", "0.61796874", "0.6136278", "0.6011399", "0.60029894", "0.5835986", "0.57988", "0.57729673", "0.57688344", "0.576683", "0.57666916", "0.57545465", "0.57303697", "0.5727659", "0.5720329", "0.5715773", "0.5688745", "0.56227094", "0.5617708...
0.5652376
19
1. Use criterial builder to create criteria query returning expected result object
@Test public void basic_select_with_whereAndLike() { CriteriaBuilder criteriaBuilder = em.getCriteriaBuilder(); CriteriaQuery<Course> criteriaQuery = criteriaBuilder .createQuery(Course.class); // 2. Define roots for the table which are used/involved in query Root<Course> courseRoot = criteriaQuery.from(Course.class); // 3. Define predicates Predicate like100Steps = criteriaBuilder.like(courseRoot.get("name"), "%100 steps"); // 4. Add Predicates to the criteria query criteriaQuery.where(like100Steps); // 5. Build Typed Query TypedQuery<Course> query = em.createQuery(criteriaQuery .select(courseRoot)); List<Course> resultList = query.getResultList(); logger.info("Simple Criteria Query Result ===> {}", resultList); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Query<T, R> build() {\n // if criteria.size == 0, rootCriterion = null\n Criterion rootCriterion = null;\n if (criteria.size() == 1) {\n rootCriterion = criteria.get(0);\n } else if (criteria.size() > 1) {\n rootCriterion = Restrictions.and(criteria\n ...
[ "0.7095852", "0.67877555", "0.67780375", "0.67779315", "0.67779315", "0.67549545", "0.67549545", "0.67549545", "0.67549545", "0.67549545", "0.6744415", "0.67350066", "0.6728442", "0.67137957", "0.67119956", "0.67119956", "0.6691049", "0.6691049", "0.6691049", "0.6691049", "0....
0.0
-1
1. Use criteria builder to create criteria query returning expected results object
@Test public void basic_courses_without_students(){ CriteriaBuilder criteriaBuilder = em.getCriteriaBuilder(); CriteriaQuery<Course> criteriaQuery = criteriaBuilder.createQuery(Course.class); //2. Define root tables which are involved into query Root<Course> courseRoot = criteriaQuery.from(Course.class); //3. Define predicate using criteria builder Predicate isEmptyStudentPredicate = criteriaBuilder.isEmpty(courseRoot.get("students")); //4. Add predictes to the criteria query criteriaQuery.where(isEmptyStudentPredicate); //5. Defined Typed Query TypedQuery<Course> query = em.createQuery(criteriaQuery.select(courseRoot)); List<Course> resultList = query.getResultList(); logger.info("isEMPTY STUDENT COURSES ==> {}", resultList); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Query<T, R> build() {\n // if criteria.size == 0, rootCriterion = null\n Criterion rootCriterion = null;\n if (criteria.size() == 1) {\n rootCriterion = criteria.get(0);\n } else if (criteria.size() > 1) {\n rootCriterion = Restrictions.and(criteria\n ...
[ "0.6787497", "0.67102766", "0.66763526", "0.66763526", "0.6668571", "0.6651006", "0.6651006", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", "0.6609135", ...
0.0
-1
Use Criteria Builder to create criteria query returning expected result object
@Test public void join(){ CriteriaBuilder criteriaBuilder = em.getCriteriaBuilder(); CriteriaQuery<Course> criteriaQuery = criteriaBuilder.createQuery(Course.class); // Define roots Root<Course> courseRoot = criteriaQuery.from(Course.class); // Define Predicate Join<Object, Object> join = courseRoot.join("students"); // Add Predicate //5. Defined Typed Query TypedQuery<Course> query = em.createQuery(criteriaQuery.select(courseRoot)); List<Course> resultList = query.getResultList(); logger.info("JOINED COURSES ==> {}", resultList); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Query<T, R> build() {\n // if criteria.size == 0, rootCriterion = null\n Criterion rootCriterion = null;\n if (criteria.size() == 1) {\n rootCriterion = criteria.get(0);\n } else if (criteria.size() > 1) {\n rootCriterion = Restrictions.and(criteria\n ...
[ "0.6826932", "0.6581682", "0.65788484", "0.65788484", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", "0.6532578", ...
0.0
-1
Use QueryBuilder to create criteria query returning expected result object
@Test public void leftJoin(){ CriteriaBuilder criteriaBuilder = em.getCriteriaBuilder(); CriteriaQuery<Course> criteriaQuery = criteriaBuilder.createQuery(Course.class); //Define Roots Root<Course> courseRoot = criteriaQuery.from(Course.class); //Define Predicates Join<Object, Object> leftJoin = courseRoot.join("students",JoinType.LEFT); //Add predicates //Define TypedQuery TypedQuery<Course> query = em.createQuery(criteriaQuery.select(courseRoot)); List<Course> resultList = query.getResultList(); logger.info("LEFT JOINED COURSES ==> {}", resultList); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Query<T, R> build() {\n // if criteria.size == 0, rootCriterion = null\n Criterion rootCriterion = null;\n if (criteria.size() == 1) {\n rootCriterion = criteria.get(0);\n } else if (criteria.size() > 1) {\n rootCriterion = Restrictions.and(criteria\n ...
[ "0.68673176", "0.68566483", "0.6585626", "0.65157634", "0.6425333", "0.63647866", "0.6342041", "0.6299162", "0.6297578", "0.62157595", "0.61534286", "0.6150786", "0.6136717", "0.6114897", "0.6091212", "0.60863894", "0.6059629", "0.6051689", "0.6047948", "0.60375535", "0.60277...
0.0
-1
TODO Autogenerated method stub
@Override public void onTestStart(ITestResult result) { test = extent.createTest(result.getMethod().getMethodName()); //part of fixing parallel run, sending a object to the pool: extentTest.set(test); }
{ "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
TODO Autogenerated method stub
@Override public void onTestSuccess(ITestResult result) { extentTest.get().pass("I successfully Pass: " + result.getName()); }
{ "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
TODO Autogenerated method stub screenshot code if failed response if API is failed extent report
@Override public void onTestFailure(ITestResult result) { extentTest.get().fail(result.getThrowable()); WebDriver driver = null; //getting driver, you only replace word driver with other variable if you need get other and make sure that variable is public.. get(result.getInstance() reprensents the @test methods as instance try { driver = (WebDriver)result.getTestClass().getRealClass().getDeclaredField("driver").get(result.getInstance()); } catch (Exception e) { //replace all catches with Exception e // TODO Auto-generated catch block e.printStackTrace(); } //getting and sending test name: try { //extent report and taking a screenshot: extentTest.get().addScreenCaptureFromPath(getScreenShotPath(result.getMethod().getMethodName(), driver),result.getMethod().getMethodName()); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@BeforeSuite\r\n\t public void setExtent() \r\n\t {\n\t htmlReporter = new ExtentHtmlReporter(System.getProperty(\"user.dir\") + \"/test-output/myReport.html\");\r\n\r\n\t htmlReporter.config().setDocumentTitle(\"Automation Report\");\t // Tile of report\r\n\t htmlReporter.config().setReportName(\"REIMBURSIFY A...
[ "0.55681884", "0.5507487", "0.5497324", "0.5487727", "0.5473739", "0.53858083", "0.53805685", "0.5356665", "0.53525436", "0.53525436", "0.53357035", "0.53329784", "0.5330475", "0.5312561", "0.5304192", "0.5303738", "0.5296541", "0.5296541", "0.5285471", "0.5272118", "0.526164...
0.5471865
5
TODO Autogenerated method stub
@Override public void onTestSkipped(ITestResult result) { extentTest.get().skip(result.getMethod().getMethodName()); }
{ "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
TODO Autogenerated method stub
@Override public void onTestFailedButWithinSuccessPercentage(ITestResult result) { }
{ "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
TODO Autogenerated method stub
@Override public void onTestFailedWithTimeout(ITestResult result) { }
{ "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
TODO Autogenerated method stub
@Override public void onStart(ITestContext context) { }
{ "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
TODO Autogenerated method stub notify that test is done
@Override public void onFinish(ITestContext context) { extent.flush(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\t\t\tpublic void test() {\n\t\t\t}", "@Test\n public void temporaryTeamClosingUnavalableOption() {\n\n }", "@Test\n void setCompleted() {\n }", "private void test() {\n\n\t}", "@Test\r\n public void testRentOut() {\r\n }", "@Test\n public void reopenClosedTeamUnavalabl...
[ "0.75604147", "0.71362704", "0.7067375", "0.70526403", "0.701898", "0.7008256", "0.6997509", "0.69809335", "0.69701934", "0.69678485", "0.6956035", "0.69422746", "0.693948", "0.69198453", "0.69181293", "0.6917692", "0.6906483", "0.68989825", "0.6887002", "0.6874474", "0.68704...
0.0
-1
TODO Autogenerated method stub Se declaran las varibles que se van a utilizar
public static void main(String[] args) { double centigrados, fahrenheit; byte opcion; System.out.println( "Elige una opción \n1-Convertir de centígrados a Fahrenheit\n2-Convertir de Fahrenheit a centígrados"); opcion = teclado.nextByte(); if (opcion == 1) { System.out.println("Introduce los grqdos centígrados:"); centigrados = teclado.nextDouble(); fahrenheit = 32+((9*centigrados)/5); System.out .print("Entonces " + centigrados + " grados centigrados son " + fahrenheit + " grados fahrenheit"); } else if (opcion == 2) { System.out.println("Introduce los grqdos Fehrenheit:"); fahrenheit = teclado.nextDouble(); centigrados = 5*((fahrenheit -32 )/9); System.out .print("Entonces " + centigrados + " grados centigrados son " + fahrenheit + " grados fahrenheit"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\n protected void getExras() {\n }", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\r\n\tpublic void tires() ...
[ "0.6303058", "0.6082873", "0.60521764", "0.5965361", "0.59616935", "0.59602696", "0.5939191", "0.5903254", "0.5903217", "0.5900323", "0.5859739", "0.58515835", "0.5848434", "0.582109", "0.5821069", "0.58077997", "0.57968146", "0.5795385", "0.57841843", "0.5783762", "0.5761155...
0.0
-1
stops the recording activity
public void stopRecording() { BLog.d(TAG, "stopRecording()"); stopLastRunnable(); mRecordingRunnable.stopRun(); try { mRecordingThread.interrupt(); } catch (Exception e) {} mRecordingThread = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void stop() {\r\n\t\tisRecording = false;\r\n\t}", "private void stopRecording() {\n\n }", "public void StopRecording()\n {\n handler.stopRecording();\n\n }", "File stopRecording();", "private void stopRecording() {\n recoTransaction.stopRecording();\n }", "private void s...
[ "0.8685508", "0.845959", "0.8386527", "0.8281552", "0.82644737", "0.82337064", "0.7954722", "0.7861393", "0.7852158", "0.7783882", "0.76432025", "0.75301147", "0.7492067", "0.74613446", "0.7429621", "0.7421295", "0.74150956", "0.7383717", "0.73489976", "0.72154045", "0.718155...
0.81416774
6
convert short to byte
private byte[] short2byte(short[] sData) { int shortArrsize = sData.length; byte[] bytes = new byte[shortArrsize * 2]; for (int i = 0; i < shortArrsize; i++) { bytes[i * 2] = (byte) (sData[i] & 0x00FF); bytes[(i * 2) + 1] = (byte) (sData[i] >> 8); sData[i] = 0; } return bytes; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "short decodeShort();", "private static byte[] shortToBytes(short value) {\n ByteBuffer bb = ByteBuffer.allocate(2);\n bb.putShort(value);\n return bb.array();\n }", "public static void main(String[] args) {\nshort i = 128;\r\nbyte shortToByte = (byte)i;\r\nSystem.out.println(shortToByte...
[ "0.73691636", "0.7186771", "0.7180978", "0.6928876", "0.684472", "0.68184024", "0.6806534", "0.679499", "0.6768881", "0.6763054", "0.67546374", "0.6745766", "0.6733284", "0.67029774", "0.66879344", "0.66724044", "0.6651976", "0.66508925", "0.6618663", "0.66066194", "0.6605940...
0.7095323
3
though that I might need it
public abstract ArithValue negate();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "private void strin() {\n\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "private void poetries() {\n\n\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n public void perish() {\n \n }", "protected boolean func_708...
[ "0.5770787", "0.57361454", "0.57138443", "0.5652479", "0.5627435", "0.5620669", "0.5606642", "0.55966854", "0.5567139", "0.55432594", "0.55358285", "0.55345404", "0.553", "0.55094653", "0.55087614", "0.55012476", "0.54848504", "0.5426113", "0.5395351", "0.53857243", "0.537771...
0.0
-1
Creates new form MusicFrame
public MusicFrame() { initComponents(); KeyEventDispatcher keyEventDispatcher; keyEventDispatcher = new KeyEventDispatcher() { Set<Integer> pressedKeys = new TreeSet<Integer>(); @Override public boolean dispatchKeyEvent(final KeyEvent e) { if (e.getID() == KeyEvent.KEY_PRESSED) { int code = e.getKeyCode(); if (pressedKeys.contains(code)) { return false; } else { pressedKeys.add(code); buttoncount += 1; previousprevioustime = System.currentTimeMillis() / 1000.0 - previoustime; previoustime = System.currentTimeMillis() / 1000.0; lastchar = String.valueOf(e.getKeyChar()); try { Piano.playNote(String.valueOf(e.getKeyChar())); } catch (Exception ex) { Logger.getLogger(MusicFrame.class.getName()).log(Level.SEVERE, null, ex); } if (on) { text.setText(Pitch.NAME_DICT.get(String.valueOf(e.getKeyChar()))); } } } if (e.getID() == KeyEvent.KEY_RELEASED) { pressedKeys.remove(e.getKeyCode()); thelist.add(new KeyNode(lastchar, previousprevioustime, System.currentTimeMillis() / 1000.0 - previoustime)); } // Pass the KeyEvent to the next KeyEventDispatcher in the chain return false; } }; KeyboardFocusManager.getCurrentKeyboardFocusManager().addKeyEventDispatcher(keyEventDispatcher); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void createGUI() {\n\t\tframe = new JFrame();\n\t\tframe.setTitle(\"My first player\");\n\t\tframe.setBounds(100, 100, 450, 300);\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tframe.getContentPane().setLayout(null);\n\t\tframe.getContentPane().setBackground(Color.PINK);\n\t\tbtnPlay.setFo...
[ "0.67411095", "0.66545177", "0.6549654", "0.6542856", "0.6513434", "0.6398316", "0.63854796", "0.63379645", "0.6217085", "0.6140758", "0.6111257", "0.6093769", "0.6083598", "0.60759157", "0.6075493", "0.6019316", "0.6003977", "0.5987401", "0.5919024", "0.5895656", "0.5870707"...
0.5768555
29
This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor.
@SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { beat = new javax.swing.JButton(); record = new javax.swing.JButton(); letempo = new javax.swing.JLabel(); testtempo = new javax.swing.JButton(); text = new javax.swing.JTextField(); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); beat.setText("Set Beat"); beat.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { beatActionPerformed(evt); } }); record.setText("Start Recording Music"); record.setEnabled(false); record.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { recordActionPerformed(evt); } }); letempo.setText("Tempo: 120"); testtempo.setText("Test Tempo"); testtempo.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { testtempoActionPerformed(evt); } }); text.setEditable(false); text.setFont(new java.awt.Font("Tahoma", 0, 60)); // NOI18N text.setHorizontalAlignment(javax.swing.JTextField.CENTER); text.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { textActionPerformed(evt); } }); javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); getContentPane().setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addContainerGap() .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addComponent(record, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addContainerGap()) .addGroup(layout.createSequentialGroup() .addComponent(text, javax.swing.GroupLayout.PREFERRED_SIZE, 139, javax.swing.GroupLayout.PREFERRED_SIZE) .addGap(18, 18, 18) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(testtempo) .addGroup(layout.createSequentialGroup() .addGap(9, 9, 9) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(letempo) .addComponent(beat)))) .addGap(0, 10, Short.MAX_VALUE)))) ); layout.setVerticalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() .addContainerGap() .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addGap(0, 15, Short.MAX_VALUE) .addComponent(letempo) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addComponent(beat) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addComponent(testtempo)) .addComponent(text)) .addGap(18, 18, 18) .addComponent(record) .addContainerGap()) ); pack(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Form() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public frmRectangulo() {\n initComponents();\n }", "public form() {\n ...
[ "0.73191476", "0.72906625", "0.72906625", "0.72906625", "0.72860986", "0.7248112", "0.7213479", "0.72078276", "0.7195841", "0.71899796", "0.71840525", "0.7158498", "0.71477973", "0.7092748", "0.70800966", "0.70558053", "0.69871384", "0.69773406", "0.69548076", "0.69533914", "...
0.0
-1
Instantiates a new Person.
public Person() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Person() {}", "public Person() {\n\t\t\n\t}", "Person createPerson();", "public Person(String name) {\n\t\tthis.name = name;\n\t\tSystem.out.println(\"Instantiated a Person Object\");\n\t}", "public Person(){\r\n\t\tsuper();\r\n\t}", "public Person() {\n\t\tthis.name = \"Unknown\"; \n\t}", "publ...
[ "0.77791154", "0.7694394", "0.7479597", "0.7231636", "0.7216514", "0.7162616", "0.7156977", "0.71544504", "0.7079488", "0.70515263", "0.70468867", "0.70430464", "0.7034667", "0.69802135", "0.6967915", "0.6959859", "0.6959553", "0.69589865", "0.6921736", "0.69110554", "0.69094...
0.7632798
4
Instantiates a new Person.
public Person(String username, String email) { this.username = username; this.email = email; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Person() {}", "public Person() {\n\t\t\n\t}", "public Person() {\n }", "public Person() {\n }", "public Person() {\n }", "public Person() {\n }", "Person createPerson();", "public Person(String name) {\n\t\tthis.name = name;\n\t\tSystem.out.println(\"Instantiated a Person Object\")...
[ "0.77791154", "0.7694394", "0.7632798", "0.7632798", "0.7632798", "0.7632798", "0.7479597", "0.7231636", "0.7216514", "0.7162616", "0.7156977", "0.71544504", "0.7079488", "0.70515263", "0.70468867", "0.70430464", "0.7034667", "0.69802135", "0.6967915", "0.6959859", "0.6959553...
0.6614852
42
Instantiates a new Person.
public Person(User user) { this.username = user.getUsername(); this.email = user.getEmail(); this.firstname = user.getFirstname(); this.lastname = user.getLastname(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Person() {}", "public Person() {\n\t\t\n\t}", "public Person() {\n }", "public Person() {\n }", "public Person() {\n }", "public Person() {\n }", "Person createPerson();", "public Person(String name) {\n\t\tthis.name = name;\n\t\tSystem.out.println(\"Instantiated a Person Object\")...
[ "0.77791154", "0.7694394", "0.7632798", "0.7632798", "0.7632798", "0.7632798", "0.7479597", "0.7231636", "0.7216514", "0.7162616", "0.7156977", "0.71544504", "0.7079488", "0.70515263", "0.70468867", "0.70430464", "0.7034667", "0.69802135", "0.6967915", "0.6959859", "0.6959553...
0.6054395
89
Generate the alignment of sentences, the test revision documents would be modified at sentence alignment
public void align(ArrayList<RevisionDocument> trainDocs, ArrayList<RevisionDocument> testDocs, int option) throws Exception { Hashtable<DocumentPair, double[][]> probMatrix = aligner .getProbMatrixTable(trainDocs, testDocs, option); Iterator<DocumentPair> it = probMatrix.keySet().iterator(); while (it.hasNext()) { DocumentPair dp = it.next(); String name = dp.getFileName(); for (RevisionDocument doc : testDocs) { if (doc.getDocumentName().equals(name)) { double[][] sim = probMatrix.get(dp); double[][] fixedSim = aligner.alignWithDP(dp, sim, option); alignSingle(doc, sim, fixedSim, option); } } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void align(ArrayList<RevisionDocument> trainDocs,\n\t\t\tArrayList<RevisionDocument> testDocs, int option, boolean usingNgram)\n\t\t\tthrows Exception {\n\t\tHashtable<DocumentPair, double[][]> probMatrix = aligner\n\t\t\t\t.getProbMatrixTable(trainDocs, testDocs, option);\n\t\tIterator<DocumentPair> it = p...
[ "0.66078836", "0.6506819", "0.6137413", "0.596225", "0.58483946", "0.58474946", "0.5812989", "0.58061755", "0.5753674", "0.5692612", "0.5623139", "0.5565848", "0.55585676", "0.5518328", "0.545025", "0.54083145", "0.533871", "0.5310309", "0.529423", "0.5292217", "0.52829534", ...
0.59953916
3
Fake align, actually copy the gold standard alignment (For the extrinsic evaluation task)
public void repeatAlign(ArrayList<RevisionDocument> docs) throws Exception { Hashtable<String, RevisionDocument> table = new Hashtable<String, RevisionDocument>(); for (RevisionDocument doc : docs) { RevisionUnit predictedRoot = new RevisionUnit(true); predictedRoot.setRevision_level(3); // Default level to 3 doc.setPredictedRoot(predictedRoot); table.put(doc.getDocumentName(), doc); ArrayList<RevisionUnit> rus = doc.getRoot().getRevisionUnitAtLevel( 0); for (RevisionUnit ru : rus) { predictedRoot.addUnit(ru.copy(predictedRoot)); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "int align();", "public void alignLocation();", "public int getAlignment() {\n/* */ return this.newAlign;\n/* */ }", "public abstract void doAlignment(String sq1, String sq2);", "public void setAlignment(int align)\n {\n this.align = align;\n }", "public void setAlign(String align) {\n ...
[ "0.71160626", "0.6648732", "0.65805244", "0.6480086", "0.64361924", "0.64010024", "0.6396194", "0.6265085", "0.6244998", "0.6155444", "0.61503834", "0.6085245", "0.6018873", "0.5985085", "0.59831285", "0.5968722", "0.5968611", "0.5900202", "0.5898636", "0.5885545", "0.5868892...
0.0
-1
Generate the alignment of sentences, the test revision documents would be modified at sentence alignment, creating the candidate revisions
public void align(ArrayList<RevisionDocument> trainDocs, ArrayList<RevisionDocument> testDocs, int option, boolean usingNgram) throws Exception { Hashtable<DocumentPair, double[][]> probMatrix = aligner .getProbMatrixTable(trainDocs, testDocs, option); Iterator<DocumentPair> it = probMatrix.keySet().iterator(); while (it.hasNext()) { DocumentPair dp = it.next(); String name = dp.getFileName(); for (RevisionDocument doc : testDocs) { if (doc.getDocumentName().equals(name)) { double[][] sim = probMatrix.get(dp); double[][] fixedSim = aligner.alignWithDP(dp, sim, option); alignSingle(doc, sim, fixedSim, option); } } } Hashtable<String, RevisionDocument> table = new Hashtable<String, RevisionDocument>(); for (RevisionDocument doc : testDocs) { RevisionUnit predictedRoot = new RevisionUnit(true); predictedRoot.setRevision_level(3); // Default level to 3 doc.setPredictedRoot(predictedRoot); table.put(doc.getDocumentName(), doc); } RevisionPurposeClassifier rpc = new RevisionPurposeClassifier(); Instances data = rpc.createInstances(testDocs, usingNgram); Hashtable<String, Integer> revIndexTable = new Hashtable<String, Integer>(); int dataSize = data.numInstances(); for (int j = 0;j<dataSize;j++) { Instance instance = data.instance(j); int ID_index = data.attribute("ID").index(); // String ID = // data.instance(ID_index).stringValue(instance.attribute(ID_index)); String ID = instance.stringValue(instance.attribute(ID_index)); AlignStruct as = AlignStruct.parseID(ID); // System.out.println(ID); RevisionDocument doc = table.get(as.documentpath); RevisionUnit ru = new RevisionUnit(doc.getPredictedRoot()); ru.setNewSentenceIndex(as.newIndices); ru.setOldSentenceIndex(as.oldIndices); if (as.newIndices == null || as.newIndices.size() == 0) { ru.setRevision_op(RevisionOp.DELETE); } else if (as.oldIndices == null || as.oldIndices.size() == 0) { ru.setRevision_op(RevisionOp.ADD); } else { ru.setRevision_op(RevisionOp.MODIFY); } ru.setRevision_purpose(RevisionPurpose.CLAIMS_IDEAS); // default of // ADD and // Delete // are // content // edits ru.setRevision_level(0); if (revIndexTable.containsKey(as.documentpath)) { ru.setRevision_index(revIndexTable.get(as.documentpath)); revIndexTable.put(as.documentpath, revIndexTable.get(as.documentpath) + 1); } else { ru.setRevision_index(1); revIndexTable.put(as.documentpath, 2); } doc.getPredictedRoot().addUnit(ru); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Before\n\tpublic void setUp() throws Exception {\n\t\tList<Paragraph> paragraphs = new ArrayList<Paragraph>();\n\t\tList<Paragraph> paragraphsWithNoSentences = new ArrayList<Paragraph>();\n\t\t\n\t\tScanner sc = null, sc1 = null;\n\t\ttry {\n\t\t\tsc = new Scanner(new File(\"testsearchtext.txt\"));\n\t\t\tsc1 = n...
[ "0.6123206", "0.607583", "0.5856456", "0.5815983", "0.5746841", "0.5619111", "0.5559944", "0.5487611", "0.538062", "0.5357623", "0.53472537", "0.53404975", "0.5336962", "0.53223807", "0.53168535", "0.5294449", "0.5288072", "0.52860767", "0.52563006", "0.5254904", "0.5218708",...
0.669303
0
Given the probMatrix of the alignment tool, modify the revision document object of its sentence alignment
private void alignSingle(RevisionDocument doc, double[][] probMatrix, double[][] fixedMatrix, int option) throws Exception { int oldLength = probMatrix.length; int newLength = probMatrix[0].length; if (doc.getOldSentencesArray().length != oldLength || doc.getNewSentencesArray().length != newLength) { throw new Exception("Alignment sentence does not match"); } else { /* * Rules for alignment 1. Allows one to many and many to one * alignment 2. No many to many alignments (which would make the * annotation even more difficult) */ if (option == -1) { // Baseline 1, using the exact match baseline for (int i = 0; i < oldLength; i++) { for (int j = 0; j < newLength; j++) { if (probMatrix[i][j] == 1) { doc.predictNewMappingIndex(j + 1, i + 1); doc.predictOldMappingIndex(i + 1, j + 1); } } } } else if (option == -2) { // Baseline 2, using the similarity // baseline for (int i = 0; i < oldLength; i++) { for (int j = 0; j < newLength; j++) { if (probMatrix[i][j] > 0.5) { doc.predictNewMappingIndex(j + 1, i + 1); doc.predictOldMappingIndex(i + 1, j + 1); } } } } else { // current best approach for (int i = 0; i < oldLength; i++) { for (int j = 0; j < newLength; j++) { if (fixedMatrix[i][j] == 1) { doc.predictNewMappingIndex(j + 1, i + 1); doc.predictOldMappingIndex(i + 1, j + 1); } } } // Code for improving } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void align(ArrayList<RevisionDocument> trainDocs,\n\t\t\tArrayList<RevisionDocument> testDocs, int option, boolean usingNgram)\n\t\t\tthrows Exception {\n\t\tHashtable<DocumentPair, double[][]> probMatrix = aligner\n\t\t\t\t.getProbMatrixTable(trainDocs, testDocs, option);\n\t\tIterator<DocumentPair> it = p...
[ "0.5735404", "0.54204124", "0.538279", "0.523364", "0.52013785", "0.5194964", "0.50557053", "0.5025195", "0.49591434", "0.49498284", "0.4937378", "0.4837073", "0.4769733", "0.4763729", "0.47622803", "0.47586516", "0.4733175", "0.4731034", "0.47211552", "0.47066045", "0.470552...
0.6996161
0
Set the predicts to be the true alignment Not implemented
public void implementPredicts(RevisionDocument doc) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\t\tpublic void setPredictSecStructure(boolean predictSecStructure) {\n\t\t\t\n\t\t}", "public void predict_all(Mat samples, Mat results)\r\n {\r\n\r\n predict_all_0(nativeObj, samples.nativeObj, results.nativeObj);\r\n\r\n return;\r\n }", "public void prediction() {\n\t\txPrior...
[ "0.5995957", "0.5963732", "0.59391826", "0.5834378", "0.5752202", "0.56181794", "0.5521541", "0.54753435", "0.5429244", "0.5392342", "0.5364016", "0.52873987", "0.52711177", "0.52169335", "0.52160084", "0.5180034", "0.5136054", "0.5116778", "0.5102549", "0.5088313", "0.505373...
0.47816893
37
Returns the value of the 'Id Edge' attribute. If the meaning of the 'Id Edge' attribute isn't clear, there really should be more of a description here...
String getIdEdge();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getID(){\n\t\treturn this.EDGE_ID;\n\t}", "E getEdge(int id);", "private SumoEdge getEdge(String id) {\n\t\treturn idToEdge.get(id);\n\t}", "Edge getEdge();", "public double getEdge()\n {\n return this.edge;\n }", "protected Edge getEdge() {\r\n\t\treturn (Edge)getModel();\r\n\t}"...
[ "0.7902855", "0.7527538", "0.73500836", "0.6908419", "0.6711274", "0.65980864", "0.65908206", "0.65624726", "0.6545106", "0.6534089", "0.65187395", "0.6505659", "0.6481916", "0.64818794", "0.6449272", "0.6429439", "0.6422122", "0.6387245", "0.63211787", "0.628736", "0.6272911...
0.82622117
0
Returns the value of the 'Id Node1' attribute. If the meaning of the 'Id Node1' attribute isn't clear, there really should be more of a description here...
String getIdNode1();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "String getIdNode2();", "@AutoEscape\n\tpublic String getNode_1();", "public String getId() {\n return _node_id;\n }", "@Override\n\tpublic java.lang.String getNode_1() {\n\t\treturn _dictData.getNode_1();\n\t}", "public String getNode_id() {\r\n\t\treturn node_id;\r\n\t}", "NodeId getNodeId();"...
[ "0.7161587", "0.71402246", "0.7069764", "0.7067108", "0.6986247", "0.682147", "0.6738384", "0.66581595", "0.66120654", "0.65635085", "0.65541106", "0.6514985", "0.6450627", "0.642638", "0.6421506", "0.6409236", "0.6407115", "0.6393189", "0.63922596", "0.63886887", "0.63564575...
0.75711876
0
Returns the value of the 'Direction' attribute. If the meaning of the 'Direction' attribute isn't clear, there really should be more of a description here...
String getDirection();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getDirection() {\n return this.direction;\n }", "public String getDirection() {\n\t\treturn this.direction;\n\t}", "public String getDirection() {\r\n return direction;\r\n }", "public String getDirection() {\n return direction;\n }", "public int getDirection()\r...
[ "0.8524122", "0.85163593", "0.8462308", "0.84191585", "0.8260397", "0.8237772", "0.8215616", "0.8215616", "0.82026196", "0.8167292", "0.8125693", "0.8125693", "0.81227136", "0.81164736", "0.8114688", "0.81002164", "0.80960643", "0.8082007", "0.8070369", "0.8031825", "0.797155...
0.81870985
9
Returns the value of the 'Id Node2' attribute. If the meaning of the 'Id Node2' attribute isn't clear, there really should be more of a description here...
String getIdNode2();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic java.lang.String getNode_2() {\n\t\treturn _dictData.getNode_2();\n\t}", "@AutoEscape\n\tpublic String getNode_2();", "public String getId2() {\n return id2;\n }", "public String getAttribute2() {\n return attribute2;\n }", "public String getAttr2() {\n return...
[ "0.72799295", "0.71095484", "0.7068337", "0.68753004", "0.6820025", "0.6820025", "0.68012416", "0.6798181", "0.67798287", "0.67798287", "0.67798287", "0.67798287", "0.67798287", "0.6771321", "0.6512976", "0.6425908", "0.6403514", "0.63206166", "0.6313945", "0.62775195", "0.61...
0.70352614
3
Returns the value of the 'Attributes' containment reference. If the meaning of the 'Attributes' containment reference isn't clear, there really should be more of a description here...
Attributes getAttributes();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Attributes getAttributes() { return this.attributes; }", "public String getAttributes() {\n\t\treturn getProperty(\"attributes\");\n\t}", "public java.lang.Integer getAttributes() {\r\n return attributes;\r\n }", "@Override\r\n\tpublic Map<String, String> getAttributes() {\r\n\t\treturn this...
[ "0.72186804", "0.7129272", "0.70121455", "0.6890845", "0.6884999", "0.6884999", "0.6880305", "0.6810354", "0.67732096", "0.675714", "0.669747", "0.6607862", "0.6599034", "0.6574979", "0.65617865", "0.65462756", "0.6532132", "0.64971364", "0.6445687", "0.64292157", "0.6427943"...
0.65453744
16
//////////////////// Focus Listener //////////////////////////
public void focusGained(FocusEvent fe) { //colEdScroller.getViewport().scrollRectToVisible(((JComponent)fe.getComponent()).getBounds(new Rectangle())); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\t\tpublic void addToFocusListener(FocusListener aFocusListener) {\n\n\t\t}", "public void focusGained( FocusEvent fe) \n {\n }", "public void focus() {}", "private void initFocusListening() {\n addFocusListener(new FocusListener() {\n private boolean firstFocusGain = true;...
[ "0.7826835", "0.77635574", "0.7726606", "0.766919", "0.7491785", "0.7491785", "0.7491785", "0.7491785", "0.7489765", "0.74769187", "0.74769187", "0.7469966", "0.74686414", "0.74686414", "0.74686414", "0.7466183", "0.7466183", "0.746472", "0.7462714", "0.74610305", "0.74610305...
0.0
-1
Utility method to print a string representing some constants.
static final String typeToString(int type) { switch (type) { case (UNKNOWN): return "UNKNOWN"; case (STRING_FIELD): return "STRING_FIELD"; case (NUMERIC_FIELD): return "NUMERIC_FIELD"; case (DATE_FIELD): return "DATE_FIELD"; case (TIME_FIELD): return "TIME_FIELD"; case (DATE_TIME_FIELD): return "DATE_TIME_FIELD"; case (TIMESTAMP_FIELD): return "TIMESTAMP_FIELD"; default: return "NOT_DEFINED"; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String toString() {\n return super.toString() + \" (\" + constants.size() + \" constants)\";\n }", "public String toString ()\n {\n return (\"CONSTANT_String\\t\" + \"stringIndex=\\t\" + stringIndex);\n }", "public String toString(){\n \treturn isConstant ? \"const \" + type : \"var ...
[ "0.7144821", "0.6875509", "0.66861016", "0.6553741", "0.65498316", "0.64062154", "0.63451886", "0.6334924", "0.62914395", "0.62645715", "0.61043316", "0.6088599", "0.60140926", "0.5943907", "0.59352905", "0.5933316", "0.59097177", "0.59054327", "0.5897951", "0.58810997", "0.5...
0.0
-1
///////////////////////// Abstract Methods //////////////////////////
protected abstract JToolBar getNorthToolbar();
{ "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 protected void prot() {\n }", "@Override\n public void perish() {\n \n }", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n public void function(...
[ "0.67888564", "0.6622722", "0.66171616", "0.6569455", "0.65059644", "0.6481421", "0.6481421", "0.64472324", "0.6366371", "0.6366371", "0.6344823", "0.6314007", "0.6311458", "0.629525", "0.629431", "0.62655073", "0.62423867", "0.62416977", "0.62189484", "0.6205208", "0.6205208...
0.0
-1
Created by ROGK on 2017/11/1.
public interface UserOperationDao{ void saveOperation(@Param(value = "operation") UserOperation operation); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "private stendhal() {\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r...
[ "0.60998625", "0.591346", "0.58770263", "0.5841905", "0.5784381", "0.5784381", "0.5777361", "0.57472414", "0.57290065", "0.5688932", "0.5657389", "0.56426835", "0.563535", "0.5634061", "0.56339306", "0.56307405", "0.5624264", "0.56197536", "0.56197476", "0.56167156", "0.56136...
0.0
-1
This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor.
@SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { jButton4 = new javax.swing.JButton(); btnBorrar = new javax.swing.JButton(); cbOpciones = new javax.swing.JComboBox<>(); jLabel1 = new javax.swing.JLabel(); jLabel2 = new javax.swing.JLabel(); jSeparator1 = new javax.swing.JSeparator(); btnSalir = new javax.swing.JButton(); PoliUser = new javax.swing.JLabel(); jLabelPoli2 = new javax.swing.JLabel(); txtPol2 = new javax.swing.JTextField(); jLabelPoliAux = new javax.swing.JLabel(); txtPolAux = new javax.swing.JTextField(); btnAccion = new javax.swing.JButton(); Resultado = new javax.swing.JLabel(); jSeparator3 = new javax.swing.JSeparator(); ResultadoFin = new javax.swing.JLabel(); PoliUser2 = new javax.swing.JLabel(); jScrollPane1 = new javax.swing.JScrollPane(); jTextArea = new javax.swing.JTextArea(); jLabel3 = new javax.swing.JLabel(); jLabel4 = new javax.swing.JLabel(); jButton4.setText("jButton1"); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); setResizable(false); btnBorrar.setText("Examinar..."); btnBorrar.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { btnBorrarActionPerformed(evt); } }); cbOpciones.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { "Seleccione...", "Evaluar P(c)", "Suma", "Multiplicación", "Es factor (x-c)", "1ra Derivada", "n-ma Derivada", "Antiderivada", "Integral definida" })); cbOpciones.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { cbOpcionesActionPerformed(evt); } }); jLabel1.setText("Polinomios"); jLabel2.setText("Ingrese Polinomio"); btnSalir.setText("Salir"); PoliUser.setText("Polinomio Usuario"); jLabelPoli2.setText("Ingrese Polinomio"); txtPol2.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { txtPol2ActionPerformed(evt); } }); jLabelPoliAux.setText("Ingrese auxiliar"); btnAccion.setText("Acción"); Resultado.setText("Resultado"); ResultadoFin.setText("Resultado: "); PoliUser2.setText("2do Polinomio del Usuario"); jTextArea.setColumns(20); jTextArea.setRows(5); jTextArea.setText("*A la hora de ingresar un polinomio debe tener en cuenta que:\n - El String “-3.1x5 - .5x3 - 3x2 + 5x” representa al polinomio −3.1x^5 − 0.5x^3 − 3x^2 + 5x^1\n - Los Strings “x8 - 1”, “+x8 - 1”, “1x8 - 1”, “+1x8 - 1” representan al polinomio x^8 − 1\n - El String “” generará, de forma alternativa, al polinomio cero\n"); jScrollPane1.setViewportView(jTextArea); jLabel3.setText("jLabel3"); jLabel4.setText("jLabel4"); javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); getContentPane().setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addContainerGap() .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jSeparator1, javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(jSeparator3)) .addContainerGap()) .addGroup(layout.createSequentialGroup() .addGap(53, 53, 53) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addComponent(jLabelPoliAux, javax.swing.GroupLayout.PREFERRED_SIZE, 113, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addComponent(txtPolAux, javax.swing.GroupLayout.PREFERRED_SIZE, 390, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(layout.createSequentialGroup() .addGap(362, 362, 362) .addComponent(jLabel1)) .addGroup(layout.createSequentialGroup() .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 640, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 149, Short.MAX_VALUE) .addComponent(btnSalir)) .addGroup(layout.createSequentialGroup() .addComponent(jLabelPoli2) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addComponent(txtPol2, javax.swing.GroupLayout.PREFERRED_SIZE, 282, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(layout.createSequentialGroup() .addComponent(ResultadoFin) .addGap(55, 55, 55) .addComponent(Resultado))) .addContainerGap()) .addGroup(layout.createSequentialGroup() .addComponent(PoliUser) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(btnAccion) .addGap(24, 24, 24)) .addGroup(layout.createSequentialGroup() .addComponent(PoliUser2) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))) .addGroup(layout.createSequentialGroup() .addGap(63, 63, 63) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addGap(24, 24, 24) .addComponent(jLabel3)) .addComponent(jLabel4, javax.swing.GroupLayout.PREFERRED_SIZE, 446, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(btnBorrar) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(cbOpciones, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addGap(100, 100, 100)) .addGroup(layout.createSequentialGroup() .addComponent(jLabel2) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))) ); layout.setVerticalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() .addContainerGap() .addComponent(jLabel1) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, 9, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jLabel2) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(btnBorrar) .addComponent(cbOpciones, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel4, javax.swing.GroupLayout.PREFERRED_SIZE, 39, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jSeparator3, javax.swing.GroupLayout.PREFERRED_SIZE, 9, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(btnAccion) .addComponent(PoliUser)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(PoliUser2) .addGap(18, 18, 18) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() .addGap(98, 98, 98) .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(layout.createSequentialGroup() .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(ResultadoFin) .addComponent(Resultado)) .addGap(13, 13, 13) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabelPoli2) .addComponent(txtPol2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabelPoliAux) .addComponent(txtPolAux, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(btnSalir))) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 0, javax.swing.GroupLayout.PREFERRED_SIZE) .addContainerGap()) ); pack(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Form() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public frmRectangulo() {\n initComponents();\n }", "public form() {\n ...
[ "0.73208135", "0.7291972", "0.7291972", "0.7291972", "0.7287118", "0.72494483", "0.7214677", "0.72086734", "0.7197058", "0.71912485", "0.7185818", "0.71596724", "0.71489036", "0.7094215", "0.7082007", "0.70579666", "0.6988024", "0.6978225", "0.6955616", "0.6955434", "0.694586...
0.0
-1
Created by mohamed on 23/04/18.
public interface ILoginView { void onLoginSuccess(String message); void onLoginError(String message); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "private stendhal() {\n\t}", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "public final void mo51373a() {\n }", "@Override\r\n...
[ "0.5986146", "0.5950038", "0.5906233", "0.58987457", "0.5778694", "0.5768805", "0.57559586", "0.57559586", "0.56966764", "0.5693241", "0.568725", "0.56852007", "0.5683547", "0.5676234", "0.5659886", "0.5659886", "0.5659886", "0.5659886", "0.5659886", "0.5659869", "0.5646996",...
0.0
-1
TODO: Warning this method won't work in the case the id fields are not set
@Override public boolean equals(Object object) { if (!(object instanceof ReservationDetail)) { return false; } ReservationDetail other = (ReservationDetail) object; if ((this.reservationDetailPK == null && other.reservationDetailPK != null) || (this.reservationDetailPK != null && !this.reservationDetailPK.equals(other.reservationDetailPK))) { return false; } return true; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void setId(Integer id) { this.id = id; }", "private Integer getId() { return this.id; }", "public void setId(int id){ this.id = id; }", "public void setId(Long id) {this.id = id;}", "public void setId(Long id) {this.id = id;}", "public void setID(String idIn) {this.id = idIn;}", "public void se...
[ "0.6896886", "0.6838461", "0.67056817", "0.66419715", "0.66419715", "0.6592331", "0.6579151", "0.6579151", "0.6574321", "0.6574321", "0.6574321", "0.6574321", "0.6574321", "0.6574321", "0.65624106", "0.65624106", "0.65441847", "0.65243006", "0.65154546", "0.6487427", "0.64778...
0.0
-1
Get the command that must be executed by a player to use the response type.
@Localized public String getCommandName() { return NucLang.get(_commandName).toString(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public network.message.PlayerResponses.Command getCommand() {\n if (responseCase_ == 2) {\n return (network.message.PlayerResponses.Command) response_;\n }\n return network.message.PlayerResponses.Command.getDefaultInstance();\n }", "public network.message.PlayerResponses.Command getCom...
[ "0.7696845", "0.75515026", "0.7536841", "0.7382658", "0.7166025", "0.6918146", "0.6555154", "0.64659995", "0.6463405", "0.6286051", "0.6262395", "0.6260819", "0.62527096", "0.6219886", "0.6195661", "0.6167847", "0.61482376", "0.61377513", "0.61129636", "0.61047196", "0.610165...
0.0
-1
/ Code to run when the op mode is initialized goes here
@Override public void init() { /// Important Step 2: Get access to a list of Expansion Hub Modules to enable changing caching methods. all_hubs_ = hardwareMap.getAll(LynxModule.class); /// Important Step 3: Option B. Set all Expansion hubs to use the MANUAL Bulk Caching mode for (LynxModule module : all_hubs_ ) { switch (motor_read_mode_) { case BULK_READ_AUTO: module.setBulkCachingMode(LynxModule.BulkCachingMode.AUTO); break; case BULK_READ_MANUAL: module.setBulkCachingMode(LynxModule.BulkCachingMode.MANUAL); break; case BULK_READ_OFF: default: module.setBulkCachingMode(LynxModule.BulkCachingMode.OFF); break; } } /// Use the hardwareMap to get the dc motors and servos by name. motorLF_ = hardwareMap.get(DcMotorEx.class, lfName); motorLB_ = hardwareMap.get(DcMotorEx.class, lbName); motorRF_ = hardwareMap.get(DcMotorEx.class, rfName); motorRB_ = hardwareMap.get(DcMotorEx.class, rbName); motorLF_.setDirection(DcMotor.Direction.REVERSE); motorLB_.setDirection(DcMotor.Direction.REVERSE); // map odometry encoders verticalLeftEncoder = hardwareMap.get(DcMotorEx.class, verticalLeftEncoderName); verticalRightEncoder = hardwareMap.get(DcMotorEx.class, verticalRightEncoderName); horizontalEncoder = hardwareMap.get(DcMotorEx.class, horizontalEncoderName); if( USE_ENCODER_FOR_TELEOP ) { motorLF_.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER); motorLF_.setMode ( DcMotor.RunMode.RUN_WITHOUT_ENCODER); motorLB_.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER); motorLB_.setMode ( DcMotor.RunMode.RUN_WITHOUT_ENCODER); motorRF_.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER); motorRF_.setMode ( DcMotor.RunMode.RUN_WITHOUT_ENCODER); motorRB_.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER); motorRB_.setMode ( DcMotor.RunMode.RUN_WITHOUT_ENCODER); verticalLeftEncoder.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER); verticalRightEncoder.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER); horizontalEncoder.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER); motorLF_.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE); motorLB_.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE); motorRF_.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE); motorRB_.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE); } if( USE_INTAKE ) { motor_left_intake_ = hardwareMap.get(DcMotorEx.class, "motorLeftIntake"); motor_right_intake_ = hardwareMap.get(DcMotorEx.class, "motorRightIntake"); motor_right_intake_.setDirection(DcMotor.Direction.REVERSE) ; motor_left_intake_.setMode( DcMotor.RunMode.STOP_AND_RESET_ENCODER ); motor_left_intake_.setMode( DcMotor.RunMode.RUN_USING_ENCODER ); motor_right_intake_.setMode( DcMotor.RunMode.STOP_AND_RESET_ENCODER ); motor_right_intake_.setMode( DcMotor.RunMode.RUN_USING_ENCODER ); servo_left_intake_ = hardwareMap.servo.get("servoLeftIntake"); servo_left_intake_pos_ = CR_SERVO_STOP ; servo_left_intake_.setPosition(CR_SERVO_STOP); servo_right_intake_ = hardwareMap.servo.get("servoRightIntake"); servo_right_intake_pos_ = CR_SERVO_STOP ; servo_right_intake_.setPosition(CR_SERVO_STOP); } if( USE_LIFT ) { motor_lift_ = hardwareMap.get(DcMotorEx.class, "motorLift"); motor_lift_.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE); motor_lift_.setMode( DcMotor.RunMode.STOP_AND_RESET_ENCODER ); power_lift_ = 0.0; if( USE_RUN_TO_POS_FOR_LIFT ) { motor_lift_.setTargetPosition(0); motor_lift_.setMode( DcMotor.RunMode.RUN_TO_POSITION ); // must call setTargetPosition() before switching to RUN_TO_POSISTION } else { motor_lift_.setMode( DcMotor.RunMode.RUN_USING_ENCODER); } last_stone_lift_enc_ = -1; } if( USE_STONE_PUSHER ) { servo_pusher_ = hardwareMap.servo.get("servoPusher"); servo_pusher_.setPosition(PUSHER_INIT); servo_pusher_pos_ = PUSHER_INIT; } if( USE_STONE_GATER ) { servo_gater_ = hardwareMap.servo.get("servoGater"); servo_gater_.setPosition(GATER_INIT); servo_gater_pos_ = GATER_INIT; } if( USE_ARM ) { servo_arm_ = hardwareMap.servo.get("servoArm"); servo_arm_.setPosition(ARM_INIT); servo_arm_pos_ = ARM_INIT; servo_claw_ = hardwareMap.servo.get("servoClaw"); servo_claw_.setPosition(CLAW_OPEN); servo_claw_pos_ = CLAW_OPEN; } if( USE_HOOKS ) { servo_left_hook_ = hardwareMap.servo.get("servoLeftHook"); servo_left_hook_.setPosition(LEFT_HOOK_UP); servo_left_hook_pos_ = LEFT_HOOK_UP; servo_right_hook_ = hardwareMap.servo.get("servoRightHook"); servo_right_hook_.setPosition(RIGHT_HOOK_UP); servo_right_hook_pos_ = RIGHT_HOOK_UP; } if( USE_PARKING_STICKS ) { servo_left_park_ = hardwareMap.servo.get("servoLeftPark"); servo_left_park_.setPosition(LEFT_PARK_IN); servo_left_park_pos_ = LEFT_PARK_IN; servo_right_park_ = hardwareMap.servo.get("servoRightPark"); servo_right_park_.setPosition(RIGHT_PARK_IN); servo_right_park_pos_ = RIGHT_PARK_IN; } if( USE_RGB_FOR_STONE ) { rev_rgb_range_ = hardwareMap.get(LynxI2cColorRangeSensor.class, "stoneColor"); //rev_rgb_range_ = hardwareMap.get(LynxI2cColorRangeSensor.class, "stoneColorV3"); // different interface for V3, can't define it as LynxI2cColorRangeSensor anymore, 2020/02/29 if( rev_rgb_range_!=null ) { if( AUTO_CALIBRATE_RGB ) { int alpha = rev_rgb_range_.alpha(); //double dist = rev_rgb_range_.getDistance(DistanceUnit.CM); double dist = rev_rgb_range_.getDistance(DistanceUnit.METER); if( alpha>=MIN_RGB_ALPHA && alpha<100000 ) { rev_rgb_alpha_init_ = alpha; } if( AUTO_CALIBRATE_RGB_RANGE && !Double.isNaN(dist) ) { if( dist>MIN_RGB_RANGE_DIST && dist<MAX_RGB_RANGE_DIST ) { rev_rgb_dist_init_ = dist; } } } } } if( USE_RGBV3_FOR_STONE ) { //rgb_color_stone_ = hardwareMap.get(ColorSensor.class, "stoneColorV3"); rgb_range_stone_ = hardwareMap.get(DistanceSensor.class, "stoneColorV3"); if( AUTO_CALIBRATE_RANGE && rgb_range_stone_!=null ) { while(true) { // wait till range sensor gets a valid reading double dis = getRangeDist(RangeName.RGB_RANGE_STONE); if( dis>0.0 && dis<0.2 ) { rgb_range_stone_dist_init_ = dis; break; } } } } if( USE_RIGHT_RANGE ) { range_right_ = (Rev2mDistanceSensor) (hardwareMap.get(DistanceSensor.class, "rightRange")); if( AUTO_CALIBRATE_RANGE && range_right_!=null ) { while(true) { // wait till range sensor gets a valid reading double dis = getRangeDist(RangeName.RANGE_RIGHT); if( dis>0.01 && dis<2.0 ) { range_right_dist_init_ = dis; break; } } } } if( USE_LEFT_RANGE ) { range_left_ = (Rev2mDistanceSensor) (hardwareMap.get(DistanceSensor.class, "leftRange")); if( AUTO_CALIBRATE_RANGE && range_left_!=null ) { while(true) { // wait till range sensor gets a valid reading double dis = getRangeDist(RangeName.RANGE_LEFT); if( dis>0.01 && dis<2.0 ) { range_left_dist_init_ = dis; break; } } } } if( USE_RANGE_FOR_STONE) { range_stone_ = (Rev2mDistanceSensor) (hardwareMap.get(DistanceSensor.class, "stoneRange")); if( AUTO_CALIBRATE_RANGE && range_stone_!=null ) { while(true) { // wait till range sensor gets a valid reading double dis = getRangeDist(RangeName.RANGE_STONE); if( dis>0.01 && dis<0.5 ) { range_stone_dist_init_ = dis; break; } } } } if( USE_INTAKE_MAG_SWITCH ) { intake_mag_switch_ = hardwareMap.get(DigitalChannel.class, "intake_mag_switch"); intake_mag_switch_.setMode(DigitalChannelController.Mode.INPUT); intake_mag_prev_state_ = intake_mag_switch_.getState(); intake_mag_change_time_ = 0.0; } if( USE_STONE_LIMIT_SWITCH ) { stone_limit_switch_ = hardwareMap.get(DigitalChannel.class, "stone_limit_switch"); stone_limit_switch_.setMode(DigitalChannelController.Mode.INPUT); stone_limit_switch_prev_state_ = stone_limit_switch_.getState(); } /////***************************** JOY STICKS *************************************///// /// Set joystick deadzone, any value below this threshold value will be considered as 0; moved from init() to init_loop() to aovid crash if(gamepad1!=null) gamepad1.setJoystickDeadzone( JOYSTICK_DEAD_ZONE ); if(gamepad2!=null) gamepad2.setJoystickDeadzone( JOYSTICK_DEAD_ZONE ); resetControlVariables(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public abstract void runOpMode();", "public abstract void initMode();", "@Override\n public void runOpMode() {\n servo0 = hardwareMap.servo.get(\"servo0\");\n servo1 = hardwareMap.servo.get(\"servo1\");\n digital0 = hardwareMap.digitalChannel.get(\"digital0\");\n m...
[ "0.7534318", "0.73335266", "0.7050642", "0.70040435", "0.69837034", "0.6947779", "0.68455285", "0.68297756", "0.68137085", "0.6802639", "0.67905587", "0.6721115", "0.66509503", "0.66446257", "0.6569132", "0.65206116", "0.64671886", "0.64622", "0.64580023", "0.63948834", "0.63...
0.59983075
36
/ This method will be called once before entering loop()
@Override public void init_loop() { loop_cnt_++; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override public void loop() {\n }", "@Override\n public void loop()\n {\n }", "@Override public void loop () {\n }", "@Override\n public void loop() {\n\n }", "@Override\n public void loop() {\n\n }", "@Override\r\n public void init_loop() {\r\n }", "@Override\r\n pu...
[ "0.756598", "0.75376886", "0.7396316", "0.73947847", "0.73947847", "0.73138785", "0.73138785", "0.73055077", "0.72986037", "0.7184208", "0.7153739", "0.71342885", "0.71342885", "0.71342885", "0.71342885", "0.71342885", "0.71342885", "0.71342885", "0.71342885", "0.71342885", "...
0.69152904
32
/ This method will be called once when the PLAY button is first pressed.
@Override public void start() { timer_.reset(); resetControlVariables(); // need reset all key counters bcz they are used in init_loop() }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void nowPlaying() {\n\t}", "public void play() {\n\t\t\r\n\t}", "public void onPlayerPlay() {\n\t\trunOnUiThread(new Runnable() {\n\t\t\tpublic void run() {\n\t\t\t\tplay.setVisibility(View.GONE);\n\t\t\t\tpause.setVisibility(View.VISIBLE);\n\t\t\t\tsetCurrentTrack();\n\t\t\t}\n\t\t});\n\t}...
[ "0.7731213", "0.77192867", "0.76894546", "0.76735127", "0.7585466", "0.7560073", "0.753749", "0.75012106", "0.7494187", "0.74347675", "0.74189943", "0.73955697", "0.73599666", "0.73554343", "0.735144", "0.73403615", "0.7328588", "0.7305083", "0.72918075", "0.7267212", "0.7223...
0.0
-1
/ This method will be called repeatedly in a loop
@Override public void loop () { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void loop()\n {\n }", "@Override public void loop() {\n }", "@Override\n public void loop() {\n\n }", "@Override\n public void loop() {\n\n }", "@Override\r\n\t\t\tpublic void run() {\n\t\t\t\t\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void run() {\n\t\t\t\t\r\n\t...
[ "0.6837796", "0.67747265", "0.6774561", "0.6774561", "0.67131066", "0.67131066", "0.67050767", "0.6683074", "0.6683074", "0.66689223", "0.66470885", "0.6589741", "0.6566706", "0.6490962", "0.6475911", "0.6461972", "0.6461972", "0.6449044", "0.64268386", "0.6419718", "0.641432...
0.66494226
10
/ Code to run when the op mode is first disabled goes here
@Override public void stop () { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void runOpMode() {\n servo0 = hardwareMap.servo.get(\"servo0\");\n servo1 = hardwareMap.servo.get(\"servo1\");\n digital0 = hardwareMap.digitalChannel.get(\"digital0\");\n motor0 = hardwareMap.dcMotor.get(\"motor0\");\n motor1 = hardwareMap.dcMotor.get(\"mot...
[ "0.7218687", "0.70883465", "0.68440586", "0.6828813", "0.67650455", "0.6723159", "0.665032", "0.6556356", "0.6555784", "0.652499", "0.6470446", "0.6459811", "0.6415281", "0.64098233", "0.64084053", "0.6385399", "0.6381864", "0.63631314", "0.63502395", "0.63021505", "0.6299293...
0.0
-1