query
stringlengths
8
1.54M
document
stringlengths
9
312k
negatives
listlengths
19
20
metadata
dict
store the nodes into a list with the postorder
@Override public List<K> getPostOrderTraversal() { List<K> nodes = new ArrayList<K>();// create a new list nodes = getPostOrderTraversal(root);// recurse to store return nodes; }
[ "public List<GenericNode<T>> postorder() {\n\t\tList<GenericNode<T>> postorderList = new ArrayList<GenericNode<T>>();\n\t\tpostorder(root, postorderList);\n\t\n\t\treturn postorderList;\n\t}", "public LinkedList<T> postorderTraversal(){\r\n\t\t\r\n\t\tLinkedList<T> postorderList= new LinkedList<T>();\r\n\t\t\r\n\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Checks if a channel is null or empty and removes any '' in front of it if necessary.
private synchronized String prepareChannel(String channel) { if (channel == null || channel.isEmpty()) { return null; } if (channel.startsWith("#")) { channel = channel.substring(1); if (channel.isEmpty()) { return null; } ...
[ "public static String clearNull(String input) {\n return isEmpty(input) ? \"\" : input;\n }", "public boolean hasChannelTitle()\n {\n return channelTitle != null && channelTitle.length() > 0;\n }", "public void setChannelNo(String channelNo) {\n this.channelNo = channelNo ==...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
error message when identical username given
static String makeExsistingUsernameMessage( final String username){ return String.format("The username '%s' is already in use!", username); }
[ "private void userNameErrorMessage(boolean exists, String userName){\n if(exists){\n System.out.println(\"\\nUserName: \" + userName + \" Already Exists In Database!\\n\");\n }\n }", "public String retryUsername(){\n pastUser = username;\n username = JOptionPane.showInput...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the last foo in the ordered set where uuid = &63; and companyId = &63;.
public Foo findByUuid_C_Last(java.lang.String uuid, long companyId, com.liferay.portal.kernel.util.OrderByComparator<Foo> orderByComparator) throws NoSuchFooException;
[ "public Foo fetchByUuid_C_Last(java.lang.String uuid, long companyId,\n\t\tcom.liferay.portal.kernel.util.OrderByComparator<Foo> orderByComparator);", "@Override\n\tpublic Arret fetchByUuid_C_Last(\n\t\tString uuid, long companyId,\n\t\tOrderByComparator<Arret> orderByComparator) {\n\n\t\tint count = countByUuid_...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates a camera calibrator using default method.
public static CameraCalibrator create() { return create(DEFAULT_METHOD); }
[ "public abstract CameraCalibratorMethod getMethod();", "public static CameraCalibrator create(final CameraCalibratorMethod method) {\n switch (method) {\n case ERROR_OPTIMIZATION:\n return new ErrorOptimizationCameraCalibrator();\n case ALTERNATING_CALIBRATOR:\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the adExclusionRuleActionType value for this AdExclusionRuleAction.
public java.lang.String getAdExclusionRuleActionType() { return adExclusionRuleActionType; }
[ "public void setAdExclusionRuleActionType(java.lang.String adExclusionRuleActionType) {\n this.adExclusionRuleActionType = adExclusionRuleActionType;\n }", "public Integer getActionType() {\n return actionType;\n }", "public String getActionType()\r\n\t{\r\n\t\treturn actionType;\r\n\t}", ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns true if field priority is set (has been assigned a value) and false otherwise
public boolean isSetPriority() { return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PRIORITY_ISSET_ID); }
[ "public boolean isSetPriority() {\n return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PRIORITY_ISSET_ID);\n }", "public boolean isSetPriority() {\n return EncodingUtils.testBit(__isset_bitfield, __PRIORITY_ISSET_ID);\n }", "boolean hasPriority();", "public boolean isSetPriorityC...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
.cfwf.client_conn.school.IDENTITY_STATUS identity_status = 2;
int getIdentityStatusValue();
[ "com.cfwf.cb.business_proto.ClientConnSchool.IDENTITY_STATUS getIdentityStatus();", "public int getIdentityStatusValue() {\n return identityStatus_;\n }", "com.cfwf.cb.business_proto.ClientConnSchool.WeikeInfo.STATUS getApproveStatus();", "trinsic.services.ProviderService.InvitationStatusResponse....
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
loads the unified Schema for the tenant
public void loadUnifiedSchema() { final String methodName = "loadUnifiedSchema"; GoliathLogger.start(log, methodName); PlatformServicesClient platformServicesClient = null; PlatformServices proxy = null; String tenantId = null; platformServicesClient = new PlatformServicesClient(); System.out.printl...
[ "@PostConstruct\n @SneakyThrows\n public void loadSchema() {\n // get the schema\n @Cleanup Reader schemaFile = new InputStreamReader(schemaResource.getInputStream());\n // parse schema\n TypeDefinitionRegistry typeRegistry = new SchemaParser().parse(schemaFile);\n RuntimeWi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Create an XML snippet to be placed in the i2b2 XML response that contains information on a result of a FURTHeR query. This includes a break down into individual data source person counts as well as join counts.
String buildQueryResultXml(QueryContextTo queryContextTo);
[ "public String marshalI2b2FurtherQueryResult(\n\t\t\tfinal I2b2FurtherQueryResultTo queryResult) {\n\t\tfinal Map<JaxbMarshallerProperty, Object> marshallerConfig = CollectionUtil\n\t\t\t\t.newMap();\n\t\tmarshallerConfig.put(JaxbMarshallerProperty.FRAGMENT, Boolean.TRUE);\n\t\tString marshalled;\n\t\ttry {\n\t\t\t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sends text to all currently connected WebSocket clients.
public void sendToAll(String text) { Collection<WebSocket> con = connections(); synchronized (con) { for (WebSocket c : con) { c.send(text); } } }
[ "private void sendTextToAllClients(String text) {\n\t\tfor (ClientManager cm : serverHolder.findAllClientManagers()) {\n\t\t\tcm.sendText(name, text);\n\t\t}\n\t}", "public void sendMessageToAllUsers(TextMessage message) {\n Collection<WebSocketSession> sessions = users.values();\n for (WebSocketSes...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the result of interpreting the object as an instance of 'Initial Node'. This implementation returns null; returning a nonnull result will terminate the switch.
public T caseInitialNode(InitialNode object) { return null; }
[ "public AOStarNode getInitNode()\r\n\t{\r\n\t\treturn (AOStarNode) initialNode;\r\n\t}", "public T caseInitialStatement(InitialStatement object) {\n\t\treturn null;\n\t}", "private State parse_initial_node()\n {\n return UmlUtil.pickup_special(elements)\n .stream()\n .map...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
repeated .org.axesoft.jaxos.network.protobuff.SquadChosen chosen = 1;
java.util.List<org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen> getChosenList();
[ "org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosen getChosen(int index);", "private SquadChosen(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }", "org.axesoft.jaxos.network.protobuff.PaxosMessage.SquadChosenOrBuilder getChosenOrBuilder(\n int index);"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
creates batter object and/or overwrites object pointer on next driver program iteration
public static Batter createBatter() { String name = createName() + " " + createName(); double average = Math.random(); Batter batter = new Batter(name, average); return batter; }
[ "BOp createBOp();", "BPObject createBPObject();", "void createBlast() {\n wand.shoot(this);\n }", "private static Bat createBat(){\n try {\n UtilityMethods.print(\"Creating Big bat for you...!\"); \n BatGenerator batGenerator = new BatGenerator();\n BatBuilder bigBa...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns a generic string builder containing the same elements in the same order as in this string. The storage concepts of the builder must be the same as in this string, so if invoke this.toGStringBuilder().toGString(), the resulting string must have the same memory and performance characteristics as this string.
@NotNull B toGStringBuilder();
[ "public StringBuilder toStringBuilder() {\n StringBuilder sb = new StringBuilder(length());\n appendChars(sb);\n return sb;\n }", "public myStringBuilder() {\n\t\t\n\t\tmyString = new char [DEFAULT_CAPACITY];\n\t\tcapacity = DEFAULT_CAPACITY;\n\t\t\n\t}", "StringT createStringT();", "p...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates a new text unit resource or updates the one passed as the parameter. You can use this method to create a new text unit or modify existing one (adding or modifying its fields' values).
public static ITextUnit buildTU (ITextUnit textUnit, String name, TextContainer source, TextContainer target, LocaleId locId, String comment) { if (textUnit == null) { textUnit = new TextUnit(""); } if (textUnit.getSkeleton() == null) { GenericSkeleton skel = new GenericS...
[ "public void addUnit() {\n\t\tAlertDialog.Builder builder = new AlertDialog.Builder(this);\n\t\tbuilder.setTitle(\"The unit name you want to add\");\n\n\t\t// Set up the input\n\t\tfinal EditText input = new EditText(this);\n\t\t// Specify the type of input expected; this, for example, sets the input as a password,...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Loads a Deadline object from the file.
private void loadDeadline(String type) { String description = parser.parseDeadlineEventDescription(type); String dateString = parser.parseDateTimeDeadline(type); LocalDate date = LocalDate.parse(dateString, DateTimeFormatter.ofPattern("dd/MM/yyyy")); Task toAdd = new Dead...
[ "private void load() throws IOException, ClassNotFoundException {\n\n if(!file.exists())\n throw new FileNotFoundException();\n\n FileInputStream f = new FileInputStream(file);\n ObjectInputStream in = new ObjectInputStream(f);\n\n leaderBoard = (List<LeaderBoardRow>) in.readO...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
public List getTheLogInUser(String given_username);
public ArrayList<Users> getTheLogInUser(String given_username);
[ "List<User> getUserByName(String name);", "public User getUserByUsername(String username);", "List<UserRepresentation> searchUserAccount(final String username);", "public List getUsers(User user);", "public Usuario getUsuario(String username);", "User getUser( String username );", "User getUserByLogin(S...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Unsets the "duration" attribute
void unsetDuration();
[ "public io.confluent.dabz.model.VisitEventAggregatedValue.Builder clearDuration() {\n fieldSetFlags()[2] = false;\n return this;\n }", "void unsetRecurrenceDuration();", "public void setDuration(int duration) {this.duration=duration;}", "void setDuration(int duration);", "public void setDuratio...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Ensure, that the connection list stays sorted, if the displayName which is the sorting criterium, is changed
public void testSortingAfterDisplayNameChange() throws Exception { // Initialize the tree with a driver and a connection JDBCDriver driver = Util.createDummyDriver(); JDBCDriverManager.getDefault().addDriver(driver); addListener(); DatabaseConnection conn2 = DatabaseConnection.c...
[ "public void doSort() {\n\t\tchannelRepository.sort(channelsManager.getSortMode());\n\t\tchannelsManager.retrieveAllChannels();\n\t\tchannelsManager.clearCheckedChannels();\n\t\tchannelsManager.clearChannelCheckboxes();\n\t\tchannelsManager.setScrollerPage(1);\n\t}", "private void showAllStreetListSorted() {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test for "removeResource" method in ResourceStack Class.
@Test public void removeResourceTest(){ ResourceStack stack5 = new ResourceStack(50, 50, 50, 50); stack5.removeResource(10, ResourceType.SHIELDS); stack5.removeResource(15, ResourceType.SERVANTS); stack5.removeResource(20, ResourceType.COINS); stack5.removeResource(25, Resour...
[ "public void Removeresource() {\n \t Testing.methodStart(\"Asteroid.Removeresource()\");\n Testing.methodEnd(\"Asteroid.Removeresource()\");\n }", "@Test\n public void removeResourcesTest() {\n depot.addResources(3);\n depot.setResourceType(ResourceType.SHIELDS);\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Formats Model node to the form of CLI script command /foo=a/bar=b/:operation(param=value,...) .
public static String formatCommand( ModelNode command ) { if( ! command.has(ClientConstants.OP) ) throw new IllegalArgumentException("'"+ClientConstants.OP+"' not defined."); if( command.get(ClientConstants.OP).getType() != ModelType.STRING ) throw new IllegalArgume...
[ "private String _makeCommand(String cmd) {\r\n \t\treturn new Uri.Builder()\r\n \t\t.scheme(\"http\")\r\n \t\t.authority(_getHostName())\r\n \t\t.path(\"index.cgi\")\r\n \t\t.appendPath(cmd)\r\n \t\t.build()\r\n \t\t.toString();\r\n \t}", "@Test\n public void testToString() {\n Command cmd = new Comma...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the "AutoForwardToName" element
public java.lang.String getAutoForwardToName() { synchronized (monitor()) { check_orphaned(); org.apache.xmlbeans.SimpleValue target = null; target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(AUTOFORWARDTONAME$12, 0); if (target ==...
[ "public org.apache.xmlbeans.XmlString xgetAutoForwardToName()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.XmlString target = null;\n target = (org.apache.xmlbeans.XmlString)get_store().find_element_user(AUTOFORWARDTONAME$12, 0);\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the attribute broadcastFilteringTypeList.
List<TapiBroadcastType> broadcastFilteringTypeList();
[ "EthCepPacBuilder broadcastFilteringTypeList(List<TapiBroadcastType> broadcastFilteringTypeList);", "TapiBroadcastFilteringMode broadcastFilteringMode();", "public FiltersListType[] getFiltersList() {\n return filtersList;\n }", "public Set<Broadcast> getSetofBroadcasts(){\n\t\treturn this.broadcast...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test the property 'accountNames'
@Test public void accountNamesTest() { // TODO: test accountNames }
[ "@Test\n\tpublic void testGetAdminAccountsByName() {\n\n\t\tList<AdminAccount> users = adminAccountService.getAdminAccountsByName(NAME1);\n\t\tassertNotNull(users);\n\t\tassertEquals(users.get(0).getUsername(), USERNAME1);\n\t}", "@Override\r\n public boolean equals(Account account) {\r\n \tif (account inst...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the origin airport name
public String getOriginAirportName() { return origin.getName(); }
[ "public java.lang.String getOriginAirport() {\r\n return originAirport;\r\n }", "public String getOriginAirport() {\r\n return originAirport;\r\n }", "public String getOriginAirport() {\n\treturn OriginAirport;\n }", "public String getDestinationAirportName() {\n return destinati...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Share the registry of parentCamelContext
public void enhanceCamelContext(CamelContext camelContext) { CompositeRegistry compositeRegistry = getCompositeRegistry(); compositeRegistry.addRegistry(parentCamelContext.getRegistry()); compositeRegistry.addRegistry(camelContext.getRegistry()); // Need to update the registry like this ...
[ "public Registry(Registry parent) {\n this.parent = parent;\n }", "CamelContext getCamelContext();", "public void registerParent(){\n \t\tparent = manager.getList(parentName);\n \t}", "public Keymap getResolveParent();", "public DefaultClientRegistry() {\n\t\tappDestination = new HashMap<String, D...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ This is the method that implements SutherlandHodgman Polygon Clipper algorithm and makes the use of the helper subroutines like inside, intersect, output to return the number of vertices.
public int polygonClipper(int in, float inx[], float iny[], float outx[], float outy[], float x0, float y0, float x1, float y1, String c){ //If there are no vertices left in the pologon, return 0 if(in <= 0){ return 0; } int outLength = 0; ...
[ "private void calculateConvexHull() {\n\t}", "int sizeOfPolygonArray();", "public char InPoly1(cPointi q)\n {\n int i = 0, i1;\n int d; \n double x;\n int Rcross=0;\n int Lcross=0;\n boolean Rstrad,Lstrad;\n cVertex vtemp = list.head; \n cVertex vtemp1;\n vtemp1 = list.head;\n int...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
String type xml to MxGraphModel
public static MxGraphModel xmlToMxGraphModel(String xmlData, int maxPageId, String username, Boolean isAppend) { if (StringUtils.isBlank(xmlData)) { return null; } try { Element rootElt = xmlStrToElement(xmlData, false); if (null == rootElt) { ...
[ "public static MxGraphModelVo xmlToMxGraphModel(String xmlData) {\n\n try {\n Element mxGraphModelXml = xmlStrToElementGetByKey(xmlData, false, \"mxGraphModel\");\n if (null == mxGraphModelXml) {\n return null;\n }\n String dx = StringCustomUtils.rec...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__XIfExpression__Group__0__Impl" $ANTLR start "rule__XIfExpression__Group__1" ../org.xtext.example.rmodp.ui/srcgen/org/xtext/example/rmodp/ui/contentassist/antlr/internal/InternalRmOdp.g:21352:1: rule__XIfExpression__Group__1 : rule__XIfExpression__Group__1__Impl rule__XIfExpression__Group__2 ;
public final void rule__XIfExpression__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { // ../org.xtext.example.rmodp.ui/src-gen/org/xtext/example/rmodp/ui/contentassist/antlr/internal/InternalRmOdp.g:21356:1: ( rule__XIfExpression__Group__...
[ "public final void rule__XIfExpression__Group__0() throws RecognitionException {\r\n\r\n \t\tint stackSize = keepStackSize();\r\n \r\n try {\r\n // ../org.xtext.example.rmodp.ui/src-gen/org/xtext/example/rmodp/ui/contentassist/antlr/internal/InternalRmOdp.g:21325:1: ( rule__XIfEx...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the attribute value for the calculated attribute DeleteFlag.
public String getDeleteFlag() { return (String) getAttributeInternal(DELETEFLAG); }
[ "public BigDecimal getDeleteFlag() {\r\n return deleteFlag;\r\n }", "public Integer getDeleteFlag() {\n return deleteFlag;\n }", "public Integer getDeleteflag() {\n return deleteflag;\n }", "public Integer getDeleted() {\n return (Integer)getAttributeInternal(DELETED);\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Return an algorithm that solves parent on a class in time c, assuming the child can be solved.
public Algorithm getParentAlgo(Complexity c) { final String why = "from "+ child.getName(); return getReductionAlgo(parent, c, why); }
[ "public Complexity fromParent(Complexity c) {\n if (c.betterOrEqual(Complexity.P))\n return c.betterThan(complexity) ? complexity : c;\n // Cliquewidth unbounded distributes DOWNWARD!\n /*if (c.equals(Complexity.NPC) &&\n \"Cliquewidth\".equals(parent.getName()) &&\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates save level crossings plot task.
public SaveLevelCrossingsPlot(SpectrumItem eqStress) { eqStress_ = eqStress; }
[ "private void saveButtonHandler() {\n setOnAction(e -> {\n FileChooser fileChooser = new FileChooser();\n fileChooser.setInitialDirectory(new File(\"resources/saves\"));\n FileChooser.ExtensionFilter extFilter = new FileChooser.ExtensionFilter(\"ser files (*.ser)\", \"*.ser\"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
to find the extension of a employee
public void extensionEmployee(){ System.out.println("Of what company is the employee?"); System.out.println(theHolding.companies()); int selected = reader.nextInt(); reader.nextLine(); if(selected > theHolding.getSubordinates().size()-1){ System.out.println("Please select a correct option"); } else{ ...
[ "java.lang.String getExt();", "public List<ExtensionDTO> getExtensionsForApprovers(String roleType, Employee employee, Locale locale) throws ExceptionEmptyResultset;", "String getExtension();", "java.lang.String getEmployeeName();", "Employee getOldestEmployee() {\n\t}", "public String getExtension();", ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns currently used bookService.
private BookService getBookService() { return bookService; }
[ "public java.lang.String getServiceBook () {\r\n\t\treturn serviceBook;\r\n\t}", "public BeepService getService() \n {\n return BeepService.this;\n }", "public com.traintium.books.service.BookLocalService getBookLocalService() {\n\t\treturn bookLocalService;\n\t}", "public ItemService getItemServ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
addAltTrans a a new alttrans using source = sourceMono and target = targetMono
public Element addAltTrans(Element transUnit, MonoLingualObject sourceMono, Vector<MonoLingualObject> targetmonos, int iMatchquality, Hashtable<String, Object> translationParameters) { try { // we should check if the source/target is already contained in the // transUnit boolean bAlreadyFound = bAltTr...
[ "private void addAltTransProperties(Element alttrans, MonoLingualObject sourceMono, MonoLingualObject targetMono)\n\t{\n\t\tElement propgroup = linguisticPropertiesToProp(\"MUL\", (LinguisticProperties) sourceMono\n\t\t\t\t.getParentMultiLingualObject().getLinguisticProperties());\n\t\talttrans.addContent(propgroup...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Calculate if there is a dialog up, and if so, what type.
private void updateDialogFlags() { modalDialogUp = false; if( currentDialogs.isEmpty() ) { return; } if( currentDialogs.peek() == DialogType.MODAL ) { modalDialogUp = true; } }
[ "public boolean isDialog()\n \t{\n \t\treturn true;\n \t}", "boolean hasDialogText();", "private AlertDialog getDialog(int type) {\n AlertDialog.Builder builder = new AlertDialog.Builder(this);\n if(type == 0){\n final Intent summary = new Intent(this, SummaryActivity.class);\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns true if field appDate is set (has been assigned a value) and false otherwise
public boolean isSetAppDate() { return this.appDate != null; }
[ "public boolean isSetDate() {\n return this.date != null;\n }", "public boolean isSetApp_id() {\n return this.app_id != null;\n }", "public boolean isSetApplicationTime() {\n return this.applicationTime != null;\n }", "public boolean isSetReviewDate() {\n return (this.reviewDate != null ?...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Add a filter mapping at the end of the current set of filter mappings.
private void add(Element filterMap) { synchronized (lock) { Element[] results = Arrays.copyOf(array, array.length + 1); results[array.length] = filterMap; array = results; } }
[ "public static void addFilterMap(WFJFilterMap filterMap) {\n validateFilterMap(filterMap);\n // Add this filter mapping to our registered set\n filterMaps.add(filterMap);\n }", "public static void addFilterMapBefore(WFJFilterMap filterMap) {\n validateFilterMap(filterMap);\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates ResourceOperatorSupplier with mocks
private ResourceOperatorSupplier mockNewCluster(StatefulSet sts, StrimziPodSet sps, List<Pod> pods) { ResourceOperatorSupplier ros = ResourceUtils.supplierWithMocks(false); StatefulSetOperator stsOps = ros.stsOperations; when(stsOps.getAsync(any(), any())).thenReturn(Future.succeededFuture(st...
[ "void registerOperation(Operator operator, OperatorTermSupplier<T> operatorTermSupplier);", "protected ResourceAccessor createResourceOpener() {\n return new ClassLoaderResourceAccessor(getClass().getClassLoader());\n }", "public abstract @Nullable SerializableSupplier<PublisherServiceStub> stubSupplier();"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
run this method stop all the munitions that are alive in case the war is end the method will wait until all munitions end there run
private void stopAllMunitions() { for (EnemyLauncher el : enemyLauncherArr) { try { if (el.getCurrentMissile() != null) { el.getCurrentMissile().join(); } el.stopRunning(); el.interrupt(); el.join(); } catch (InterruptedException e) { e.printStackTrace(); } } for (LauncherD...
[ "public void shutdown(){\n for (Map.Entry<String, AdmwlWorker<Result>> workerEntry : workers.entrySet()) {\n try {\n logger.info(\"Shutting down worker {}\", workerEntry.getKey());\n workerEntry.getValue().shutdown(true);\n\n } catch (RemoteException e) {\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Create a copy of this action.
@Override public IncrementAction copy() { return copy(new IncrementAction()); }
[ "public abstract Action copy();", "public Action getCopyAction() {\n return copyAction;\n }", "IAction<A, M> clone();", "public Action getCopyAction () {\n\t\treturn copyAction;\n\t}", "Copy createCopy();", "public static Action getCopy(AssignmentAction action) {\n\t\tAction actioncopy = (Action...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
GENLAST:event_addSourceButtonActionPerformed remove selected source files.
private void removeSourceButtonActionPerformed(java.awt.event.ActionEvent evt)//GEN-FIRST:event_removeSourceButtonActionPerformed {//GEN-HEADEREND:event_removeSourceButtonActionPerformed removeSelectedFromList(sourceList); }
[ "private void removeSelectedFiles() {\n final ListView<String> fileList = view.getFileList();\n final List<String> selectedFiles = FXCollections.observableArrayList(fileList.getSelectionModel().getSelectedItems());\n\n for (final String fileName : selectedFiles) {\n view.getFileList(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Instantiates a new Object manager and creates array of level objects by level id.
public ObjectManager(Level level, HiddenNature hiddenNature){ hn = hiddenNature; prefs = new PrefHandler(level, hn); isLoad = prefs.loadLevel(); id = level.getLevelID(); if (!isLoad) { switch (this.id) { case 1: entities....
[ "public Level(String id)\n \t{\n \t\tdata = new LevelData(id);\n \t\tthis.world = Engine.world;\n \t}", "public GLaDOS(int levelid){\n\t\tstats = new LevelStats(levelid);\n\t}", "protected List<Level> createLevelList(){\n\t\treturn Arrays.asList(\n//\t\t\t\tnew LevelFlat(this),\n\t\t\t\tnew LevelHilly(this),\n\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
initialize the KeywordFinder from a configuration Note that this does nothing in the test implementation as there is nothing to configure
public void init(KeywordFinderConfiguration kfc) { }
[ "public KedaConfiguration() {\n }", "@PostConstruct\n @SuppressWarnings(\"unchecked\")\n protected void initialize() {\n checkRequiredFields();\n try {\n // Create new instance of ConfigurationFileManager:\n ConfigurationFileManager cfm = new ConfigurationFileManager(\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Mark an assignment finished.
public void markAssignmentFinished(final MaintenanceAssignment assignment) { if (assignment.getStatus() != MaintenanceStatus.IN_PROGRESS) { throw new MaintenanceException("This assignment is not in progress", assignment); } assignment.setStatus(MaintenanceStatus.FINISHED); up...
[ "public void markComplete() {\n this.complete = true;\n }", "public void markAsDone() {\n this.isDone = true;\n }", "public void markComplete()\n {\n setCount(getGoal());\n }", "public void markInspectionDone(final MaintenanceAssignment assignment) {\n if (assignment.ge...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates the SelectLocationActivity view. initiate the database service DBService, sets content view builds the AutoCompleteTextView based on all the selectable Locations in the database. Also initiates the template buttons.
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.location_layout); getSupportActionBar().setTitle(R.string.choose_location); instance = this; // instantiate datasource LocationRepo locationDataSour...
[ "@Override\n protected void onCreate(@Nullable Bundle savedInstanceState) {\n super.onCreate(savedInstanceState);\n setContentView(R.layout.activity_map);\n mSearchText = (AutoCompleteTextView) findViewById(R.id.input_search);\n mGps = (ImageView) findViewById(R.id.ic_gps);\n /...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
use hadoop2.7.4 spark 1.5.1 apache
private static void test1() throws IOException { String pyFileStr = "src/main/java/org/apache/spark/util/iris_c.py"; File pyFile = new File(pyFileStr); System.out.println(pyFile.toURI().toString()); String[] args = { "--class","org.apache.spark.deploy.PythonRunner", ...
[ "private org.apache.spark.SparkConf getConf(java.util.Map<String, String> tuningConf) throws java.lang.Exception {\n org.apache.spark.SparkConf sparkConfiguration = new org.apache.spark.SparkConf();\n sparkConfiguration.set(\"spark.serializer\", \"org.apache.spark.serializer.KryoSerializer\");\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Divide a (sub)sentence recursively by a trained NST.
public void divideSen(DefaultMutableTreeNode subtree,String[] tokens,String cxt,ArrayList<String> seqs){ //no more tokens if(tokens.length==0){ String[] cxtTokens = cxt.split(" "); String realCxt = StringUtils.join(Arrays.copyOfRange(cxtTokens,Math.max(0,cxtTokens.length-this.order+1),cxtTokens.length)," "); ...
[ "public void parseSentence(String sentence)\r\n\t{\r\n\t //a check for nothingness\r\n\t if( (sentence == null)||(sentence.trim().length() == 0) ) \r\n\t \treturn;\r\n\t\ttry\r\n\t\t{\t\t\r\n\t\t\t//------------ Begin Parser\tPipeline ----------------//\r\n\t\t try\r\n\t\t {\r\n\t\t \t//-----//\r\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Attachment keys used by JWT.
interface JwtAttachments { AttachmentKey<Credential> CREDENTIAL_KEY = AttachmentKey.create(Credential.class); AttachmentKey<Integer> AUTH_FAILED_KEY = AttachmentKey.create(Integer.class); AttachmentKey<String> AUTH_MESSAGE_KEY = AttachmentKey.create(String.class); AttachmentKey<Authentic...
[ "public Object attachment(Object key);", "public BencodeableDictionary keysToAddToExtendedHandshake();", "public byte[] getFileKey() {\n return fileKey;\n }", "public ContentKeyPolicyPlayReadyContentEncryptionKeyFromKeyIdentifier() {\n }", "private static void loadKeys() {\n try { ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Convert file's pathname to a form acceptable to ZIP files
public static String convertToZIPName (String root,File f) throws IOException { String pname = f.getCanonicalPath(); String rootname = root.substring(root.lastIndexOf(File.separatorChar) + 1); pname = pname.substring(root.length() + 1); pname = pname.replace(File.separatorChar, '/'); return (rootname + "/" + pn...
[ "private String generateZipEntry(String file){\n\t\tString sourceFolder = SDCARD + TMP_STORAGE;\n\t\treturn file.substring(sourceFolder.length(), file.length());\n\t}", "public File canonicalFile(String path) throws IOException {\n \t//TODO: canonicalFile\n return new File(path);\n }", "String reso...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Aggiunge una foto all'utente come URL
@Override public void addFoto(long idUtente, String url) { Utente ut = utenteFacade.find(idUtente); ut.setHome(url); utenteFacade.edit(ut); }
[ "public void procesarURL_TXT() {\n\t\tArrayList<String> ULRs = new FileManager().getLines(Album);\n\t\tint index = 0;\n\t\tImagenes = new ArrayList();\n\t\tTags = new ArrayList();\n\t\twhile (index != ULRs.size()) {\n\t\t\ttry {\n\t\t\t\tArrayList info = getImageInfo(ULRs.get(index));\n\n\t\t\t\tSystem.out.println(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Issue a GET REST call that returns an CommentsResponse object.
CommentsResponse callCommentGetRESTCall(String methodName, String urlTemplate, Object... params) throws PropertyServerException { return (CommentsResponse)this.callGetRESTCall(methodName, CommentsResponse.class, ur...
[ "public static AllComments getAllComments() {\n String baseUrl = prop.getProperty(BASE_URL);\n String commentsEndpoint = prop.getProperty(COMMENTS_ENDPOINT);\n String url = baseUrl + commentsEndpoint;\n log.info(\"URL to be hit:\" + url);\n\n Response response = when().get(url);\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Splitted die Zahl in ein int[] der groese 4.
protected int[] splitNum(){ int[] retval = new int[4]; int num = x; for( int i =0; i<4;i++){ retval[i] = num % 10; num = num / 10; } return retval; }
[ "public int[] pre4(int[] nums)\r\n\t{\r\n\t\tint i;\r\n\t\tfor (i = 0; nums[i] != 4; i++);\r\n\t\tint[] list = new int[i--];\r\n\t\twhile (i >= 0)\r\n\t\t\tlist[i] = nums[i--];\r\n\t\treturn list;\r\n\t}", "public int[] pre4(int[] nums) {\n\n\t\tint length = 0;\n\n\t\tfor (int i=0; nums[i]!=4; i++) {\n\t\t\tlengt...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test of agregarRegistroConsulta method, of class SistemaAlimentacionSaludable.
@Test public void testAgregarRegistroConsulta() { expConsulta = cargaDeDatos.cargarConsulta(expConsulta, expAlimento, expProfesional, expUsuario); expSistema.agregarRegistroConsulta(expConsulta); }
[ "@Test\r\n\tpublic void CT01ConsultarUsuario_com_sucesso() {\r\n\t\t// cenario\r\n\t\tUsuario usuario = ObtemUsuario.comDadosValidos();\r\n\t\tUsuario resultadoObtido = null;\r\n\t\tDAOFactory mySQLFactory = DAOFactory.getDAOFactory(DAOFactory.MYSQL);\r\n\t\tIUsuarioDAO iUsuarioDAO = mySQLFactory.getUsuarioDAO();\r...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/GamePlayer Hero1 = new GamePlayer(120,120); Hero1.setPosition(12,3); System.out.println("Sebelum lari "+Hero1.getX()); Hero1.Run(12); System.out.println("Setelahnya lari "+Hero1.getX()); GamePlayer Hero2 = new GamePlayer(); Hero2.setDimension(120,120); System.out.println("panjang hero 2 ="+Hero2.getWidth());
public static void main(String[] args){ GamePlayer hero = new GamePlayer(); hero.setDimension(12,12); hero.setPosition(10,220); System.out.println("Posisi Player: "+hero.getX()+","+hero.getY()); hero.Run(12); System.out.println("Posisi Player: "+hero.getX()+","+hero.getY()); GamePlayer hero...
[ "@Test\n public void testGetWidth() {\n System.out.println(\"getWidth\");\n Player instance = new Player(50, 30, 30, 50);;\n int expResult = 30;\n int result = instance.getWidth();\n assertEquals(\"Expected Result\",expResult, result);\n }", "public void makeHero()\r\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ Converted with The Runtime Converter (runtimeconverter.com) vendor/phpunit/phpcodecoverage/src/Driver/Driver.php
public interface Driver { public static final Object CONST_LINE_EXECUTED = 1; public static final Object CONST_LINE_NOT_EXECUTED = -1; public static final Object CONST_LINE_NOT_EXECUTABLE = -2; public static final Object CONST_class = "SebastianBergmann\\CodeCoverage\\Driver\\Driver"; }
[ "@DSComment(\"Private Method\")\n @DSBan(DSCat.PRIVATE_METHOD)\n @DSGenerator(tool_name = \"Doppelganger\", tool_version = \"2.0\", generated_on = \"2013-12-30 12:30:41.838 -0500\", hash_original_method = \"C84559B4D56F542F69C4278CF0320D22\", hash_generated_method = \"A2A56B2752C42F4BF0472BA7D64B9338\")\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Builds a Credential from the Trusted Credential Environment information contained in the BiBusHeader. A trusted environment variable is an environment variable that has been set by a trusted party (i.e. a Cognos gateway, the dispatcher or a trusted signon namespace). The required variable is identified in a SystemRecov...
public static Credential getCredentialFromTrustedEnvironmentVaribleValue(final IBiBusHeader biBusHeader) { boolean credentialsFound = false; final Credential credential = new Credential(); final String[] usernames = biBusHeader.getTrustedEnvVarValue("REMOTE_USER"); if (usernames != null && usernames.length > ...
[ "public static Credential getCredentialFromTrustedEnvironmentVaribleValue(final IBiBusHeader2 biBusHeader2) {\n\t\tboolean credentialsFound = false;\n\n\t\tfinal Credential credential = new Credential();\n\t\tfinal String[] usernames = biBusHeader2.getTrustedEnvVarValue(\"REMOTE_USER\");\n\n\t\tif (usernames != nul...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
A dao interface provides methods to access database table f_capital_appropriation_apply_receipt. This file is generated by specialmerdalgen, a DAL (Data Access Layer) code generation utility specially developed for paygw project. PLEASE DO NOT MODIFY THIS FILE MANUALLY, or else your modification may be OVERWRITTEN by s...
@SuppressWarnings("rawtypes") public interface FCapitalAppropriationApplyReceiptDAO { /** * Insert one <tt>FCapitalAppropriationApplyReceiptDO</tt> object to DB table <tt>f_capital_appropriation_apply_receipt</tt>, return primary key * * <p> * The sql statement for this operation is <br> * <tt>insert in...
[ "public int update(FCapitalAppropriationApplyReceiptDO FCapitalAppropriationApplyReceipt) throws DataAccessException;", "public interface I_Z_ConfirmacionEtiquetaProd \n{\n\n /** TableName=Z_ConfirmacionEtiquetaProd */\n public static final String Table_Name = \"Z_ConfirmacionEtiquetaProd\";\n\n /** AD_T...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method removes all elements from the VMultiplicities list.
public void clearVMultiplicities() { if(this.VMultiplicities != null) { this.VMultiplicities.clear(); fireChangeEvent(); } }
[ "public void removeAllVMultiplicities(java.util.Collection<INTEGER> VMultiplicities)\n\t{\n\t\tif(this.VMultiplicities != null)\n\t\t{\n\t\t\tthis.VMultiplicities.removeAll(VMultiplicities);\n\t\t\tfireChangeEvent();\n\t\t}\n\t}", "public void removeVMultiplicities(INTEGER VMultiplicities)\n\t{\n\t\tif(this.VMult...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
iterate through two collections of the same type in the same position and return first matching element
static <E> E stepThroughCollections(Collection<E> c1, Collection <E> c2) { E match = null; Iterator<E> i1 = c1.iterator(); Iterator<E> i2 = c2.iterator(); while (i1.hasNext() && i2.hasNext()) { E e = i1.next(); if(e.equals(i2.next())) { match = e; break; } } return match; }
[ "public static <E> Iterable<E> fastJoin(final Iterable<E> collection1, final Iterable<E> collection2) {\n return new Iterable<E>() {\n\n @Override\n public Iterator<E> iterator() {\n return new Iterator<E>() {\n\n private Iterator<E> a = collection1.ite...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the port harbour code of this temp general declaration.
public void setPortHarbourCode(String portHarbourCode);
[ "public void setPortHarbourCode(java.lang.String portHarbourCode) {\n\t\t_dmPortHarbour.setPortHarbourCode(portHarbourCode);\n\t}", "@Override\n\tpublic void setPortHarbourCode(java.lang.String portHarbourCode) {\n\t\t_tempNoTiceShipMessage.setPortHarbourCode(portHarbourCode);\n\t}", "public void setPortHarbour...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the back button on the controller.
public JoystickButton getButtonBack() { return button[6]; }
[ "public JButton getBtnBack(){\n\t\treturn btnBack;\n\t}", "public boolean getButtonBack() {\n\t\treturn joystick.getRawButton(this.buttBack);\n\t}", "public int getBackKeyCode() {\n // TODO::\n return 0;\n }", "protected String getBackButtonIfAvailable(Dialog dialog) {\n if (sessionData.st...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the value of the field histogramItems.
public void setHistogramItems(List<ResolvedSuspenseHistoryReportHistogramItem> histogramItems) { this.histogramItems = histogramItems; }
[ "public void setData(Item i)\r\n\t{\r\n\t\ttheItem = i;\r\n\t}", "public synchronized void set(int itemIndex, int columnIndex, Object value) {\r\n\t\tcheckItemsBounds(itemIndex);\r\n\t\tcheckColumnsBounds(columnIndex);\r\n\t\t//\r\n\t\tObject[] values = (Object[])items.elementAt(itemIndex);\r\n\t\t//\r\n\t\tif (v...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Closes the sailing screen. This then makes checks with the game logic if the game is still playable. If it is it will launch the game back to the main screen. Otherwise it will close the main screen and launch the end screen.
public void closeSailScreen(SailScreen sailWindow, boolean sailed) { sailWindow.closeWindow(); mainWindow.getFrame().setVisible(true); // Checked if we have sailed. if (sailed) { // If we have sailed is the game still active. This checks pirates have killed the player. if (!game.getGameActive()) { // ...
[ "public void endGame() {\n if (numShots == 0) {\n Window.close();\n }\n }", "public void close()\r\n {\r\n gameInstance.setActiveGui(null);\r\n }", "public void closeScreen(){\r\n Platform.exit();\r\n }", "public void closeGame() {\r\n if(gameEngine.is...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Return all resource methods for the given path, ignoring HTTP method, consumed or produced mimes and so on.
public Collection<ResourceMethod> getMethodsForPath( RemainingPath remainingPath) { // NICE results may be chached, if any method is returned. // The 404 case will be called rarely and produce a lot of cached data. final List<ResourceMethod> resourceMethods = new ArrayList<Resour...
[ "Collection<HttpMethod> getMinimalSupportedHttpMethods();", "Set<HttpMethod> allowedMethods(String uri);", "public List<ResourceMethod> getResourceMethods() {\n return resourceMethods;\n }", "public List getAllowedMethods() throws WebDAVException;", "public List<Method> getMethodsByType(String typ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Generate the Inventory Valuation
private void generateInventoryValue(int M_Warehouse_ID,int M_CostType_ID ,int M_CostElement_ID) { setWhere(M_Warehouse_ID, M_CostType_ID, M_CostElement_ID); StringBuffer insert = new StringBuffer(); insert .append("INSERT INTO T_InventoryValue ") .append("(AD_PInstance_ID,DateValue,...
[ "private static Inventory makeInv(){\n\t\t\n\t\tint quantity = 0;\n\t\tString name;\n\t\tdouble costPer = 0;\n\t\t\n\t\tSystem.out.print(\"\\nWhat is the name?: \");\n\t\tname = keyboard.next();\n\t\tSystem.out.print(\"\\nWhat is the quantity?: \");\n\t\tquantity = keyboard.nextInt();\n\t\tSystem.out.print(\"\\nWha...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Apply a list of operations from a single delta to the wavelet container.
protected void applyWaveletOperations(List<WaveletOperation> ops) throws OperationException, EmptyDeltaException { if (ops.isEmpty()) { LOG.warning("No operations to apply at version " + currentVersion); throw new EmptyDeltaException(); } WaveletOperation lastOp = null; int opsApplied...
[ "Object apply( Object object, Delta delta );", "public abstract void adjustDeltas(Vec3 delta[]);", "List<CoreWaveletOperation> toCoreWaveletOperations() {\n List<CoreWaveletOperation> operations = new ArrayList<CoreWaveletOperation>();\n for (SegmentId segment : segmentsToRemove) {\n operations.add(n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets Flight fl's origin to origin.
public void setOrigin(Flight fl, String origin) { fl.setOrigin(origin); }
[ "public void setOrigin(Vector3f origin) {\r\n\t\tmOrigin.set(origin);\r\n\t}", "public void setCameraOrigin(Vec4df origin) {\n cameraObj.setOrigin(origin);\n setMatView(cameraObj.getMatView());\n }", "void setOrigin();", "private void setOrigin() {\n Hep3Vector origin = VecOp.mult(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
boolean isValid() Method iterateUsSysNbrUshortAddrKey
public java.util.Iterator<Integer> iterateUsSysNbrUshortAddrKey() { return this._usSysNbrUshortAddrKeyList.iterator(); }
[ "public boolean removeUsSysNbrUshortAddrKey(int vUsSysNbrUshortAddrKey)\r\n {\r\n boolean removed = _usSysNbrUshortAddrKeyList.remove(new java.lang.Integer(vUsSysNbrUshortAddrKey));\r\n return removed;\r\n }", "private boolean validUserRegistrationCheck() {\n if (myUserInfo == null)\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the value of the apId property.
public long getApId() { return apId; }
[ "public void setApId(long value) {\n this.apId = value;\n }", "public Long getPapId() {\n return papId;\n }", "public java.lang.String getApCode() {\n return apCode;\n }", "public int getAId() {\n return instance.getAId();\n }", "public String getaId() {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by MyBatis Generator. This method returns the value of the database column TRSDET_SWITCHED.REVERSED_BY
public String getREVERSED_BY() { return REVERSED_BY; }
[ "public String getREVERSED_BY()\r\n {\r\n\treturn REVERSED_BY;\r\n }", "public void setREVERSED_BY(String REVERSED_BY) {\r\n this.REVERSED_BY = REVERSED_BY == null ? null : REVERSED_BY.trim();\r\n }", "public String getREVISED_BY() {\r\n return REVISED_BY;\r\n }", "public void setREN...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
set book item expand mode
public void setExpand(boolean expand) { this.expand = expand; }
[ "public void expand() {\n openItems();\n }", "@Override\n public boolean onMenuItemActionExpand(MenuItem item) {\n return true;\n }", "@Override\n public boolean onMenuItemActionExpand(MenuItem item) {\n return true;\n }", "public void expand() {\n getS...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
A channel with the given name of type VFloat.
public static ChannelExpression<VFloat, Float> vFloat(String name) { return channel(name, VFloat.class, Float.class); }
[ "public static ChannelExpression<VFloatArray, ArrayFloat> vFloatArray(String name) {\n return channel(name, VFloatArray.class, ArrayFloat.class);\n }", "public void setChanneldataFloat(final String channelName, final float[] data) {\r\n final List<Object> dataList = new ArrayList<Object>(data.len...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
SELECT FROM BUSINESS B, MAIN_CATE M, SUB_CATE S WHERE M.CAT_ID=B.CATEGORIES AND (M.CAT_ID=1) AND B.BUSINESS_ID=S.BUSINESS_ID AND (S.NAME = 'Swimming Lessons/Schools')
private void createMainQuery() { StringBuilder sb = new StringBuilder("SELECT B.*, M.NAME AS MAIN_CATEGORY FROM BUSINESS B, MAIN_CATE M \nWHERE M.CAT_ID=B.CATEGORIES AND (M.CAT_ID="); boolean first = true; for(JCheckBox bo: boxes) { if(bo.isSelected()) { if(first) { sb.append(bo.getActionCom...
[ "String getCategoryBySubCategory(String subCategory) throws DataBaseException;", "public Map[] Subquery(String Category);", "public static void exploreQualifications() throws ClassNotFoundException, SQLException\r\n\t{\r\n\t\tConnection conn = null;\r\n\t\tStatement stmt = null, stmt2 = null;\r\n\t\tResultSet r...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Getter method for property qoffsetcell.
public String getQoffsetcell() { return qoffsetcell; }
[ "public void setQoffsetcell(String qoffsetcell) {\n\t\tthis.qoffsetcell = qoffsetcell;\n\t}", "public String getCellindividualoffset() {\n\t\treturn cellindividualoffset;\n\t}", "public Cell getPosition() {\n return position;\n }", "public SubCell position() {\r\n return position;\r\n }"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
GET all Catalogs with parentId = 0
public List<Catalogs> getAllCatalogsNoParent() { Session session = SufeeHibernateUtil.getSessionFactory().openSession(); session.beginTransaction(); try { List<Catalogs> catalogses = session.createQuery("from Catalogs where (catalogStatus = 1 or catalogStatus = 0) and parentId = 0")....
[ "public List<Catalogs> getAllParentCatalogs() {\n Session session = SufeeHibernateUtil.getSessionFactory().openSession();\n session.beginTransaction();\n try {\n List<Catalogs> catalogses = session.createQuery(\"from Catalogs where (catalogStatus = 1 or catalogStatus = 0) and parentI...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "ruleXImportDeclaration" $ANTLR start "entryRuleQualifiedNameInStaticImport" InternalDsl.g:9646:1: entryRuleQualifiedNameInStaticImport returns [String current=null] : iv_ruleQualifiedNameInStaticImport= ruleQualifiedNameInStaticImport EOF ;
public final String entryRuleQualifiedNameInStaticImport() throws RecognitionException { String current = null; AntlrDatatypeRuleToken iv_ruleQualifiedNameInStaticImport = null; try { // InternalDsl.g:9647:2: (iv_ruleQualifiedNameInStaticImport= ruleQualifiedNameInStaticImport EOF...
[ "public final String entryRuleQualifiedNameInStaticImport() throws RecognitionException {\n String current = null;\n\n AntlrDatatypeRuleToken iv_ruleQualifiedNameInStaticImport = null;\n\n\n try {\n // ../org.xtext.scripting/src-gen/org/xtext/scripting/parser/antlr/internal/InternalS...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the industryTrend value for this Account.
public void setIndustryTrend(java.lang.String industryTrend) { this.industryTrend = industryTrend; }
[ "public void setAccountTrend(java.lang.String accountTrend) {\n this.accountTrend = accountTrend;\n }", "public void setTrend(Float trend) {\n this.trend = trend;\n }", "public java.lang.String getIndustryTrend() {\n return industryTrend;\n }", "public void setIndustry(String in...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Create a new CommonIronJacamarImpl.
protected CommonIronJacamarImpl(TransactionSupportEnum transactionSupport, Map<String, String> configProperties, List<CommonAdminObject> adminObjects, List<CommonConnDef> connectionDefinitions, List<String> beanValidationGroups, String bootstrapContext) { super(); this.transactionSuppor...
[ "public ICommonInfra createInfra() {\n\t\tCommonInfra infr = new CommonInfra();\n\t\tfor(Enumeration<Class> en = infImplMap.keys(); en.hasMoreElements(); )\n\t\t{\n\t\t\tClass cls = en.nextElement();\n\t\t\tinfr.addInterface(cls, infImplMap.get(cls));\n\t\t}\n\t\treturn infr;\n\t}", "Container createContainer();"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Ensure wait on task.
public void testWaitForTask() { final long WAIT_TIME = 10000; // Lock final Object lock = new Object(); // Flag to indicate returned from wait final boolean flag[] = new boolean[1]; flag[0] = false; // Wait until new thread is running synchronized (lock) { // Wait on Task new Thread(new Runna...
[ "void youHaveToWait();", "String getWaitForTaskToComplete();", "@Substitute\n public static void onSpinWait() {\n }", "public Status waitUntilFinished();", "public synchronized void waitPoint() {\n try {\n while (isLocked) {\n wait();\n }\n } ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Caches the foo in the entity cache if it is enabled.
public void cacheResult(Foo foo);
[ "public void cacheResult(com.sohlman.liferay.foobar.model.Foo foo);", "public void cacheResult(LocalEntity localEntity);", "public void preCacheEntity(Entity entity) {\n Location location = entity.getLocation();\n Collection<Entity> entities = this.entityCache.getIfPresent(new ChunkLocation(entity...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Compares the id values of the two objects. Both objects must implement the IDReferenced interface otherwise a ClassCastException will be thrown
public int compare(Object a,Object b){ return ((IDReferenced)a).getID()-((IDReferenced)b).getID(); }
[ "@Override public int compare(final IdentifiedObject o1, final IdentifiedObject o2) {\n Collection<Identifier> a1 = o1.getIdentifiers();\n Collection<Identifier> a2 = o2.getIdentifiers();\n if (a1 == null) a1 = Collections.emptySet();\n if (a2 == null) a2 = Collections.emptySet();\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Changes to cluster OR store definition metadata results in routing strategies changing. These changes need to be propagated to all the listeners.
private void updateRoutingStrategies(Cluster cluster, List<StoreDefinition> storeDefs) { VectorClock clock = new VectorClock(); if(metadataCache.containsKey(ROUTING_STRATEGY_KEY)) clock = (VectorClock) metadataCache.get(ROUTING_STRATEGY_KEY).getVersion(); logger.info("Updating routi...
[ "private void initSystemRoutingStrategies(Cluster cluster) {\n HashMap<String, RoutingStrategy> routingStrategyMap = createRoutingStrategyMap(cluster,\n makeStoreDefinitionMap(getSystemStoreDefList()));\n this.metada...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method sets default values on all _required_ data fields in the data repository.
protected void initDataFields() { //this module doesn't require any data fields }
[ "private void fillMandatoryFields() {\n\n username(\"DefaultString\");\n name(\"DefaultString\");\n phoneNumber(\"DefaultString\");\n password(\"DefaultString\");\n acceptedCommercial(true);\n acceptedTerms(true);\n userType(true);\n }", "private void fillMandatoryFields() {\n\n }", "publ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Decode and store the data from an input buffer.
protected void decode(ByteBuffer inputBuf, int startIdx) throws DerDecodingException { int idx = startIdx; int payloadSize = decodeHeader(inputBuf, idx); int skipBytes = header_.remaining(); if (payloadSize > 0) { idx += skipBytes; payload_.ensuredPut(inputBuf, idx, idx + payloadSize); ...
[ "T decode1(DataBuffer buffer);", "public static void decodeIncommingData(IoBuffer in, IoSession session) {\n log.trace(\"Decoding: {}\", in);\n // get decoder state\n DecoderState decoderState = (DecoderState) session.getAttribute(DECODER_STATE_KEY);\n if (decoderState.fin == Byte.MIN_...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
test breaking a one to one link. 1 to 1 Association: User Person Collection Properties: TestUser.person [0..1] Person.user [0..1]
@Test public void testRemoveLinkMult1to1() { // create 1 TestUser and 2 Person Person martin = new Person("\"Bl�mel\" \"Martin\" \"19641014\""); TestUser umartin = new TestUser("martin"); umartin.setPerson(martin); Assert.assertSame(martin, umartin.getPerson()); Assert.assertSame(umartin, martin.getUser()...
[ "@Test\n\tpublic void testAddLinkOkMult1to1Second() {\n\n\t\t// set up\n\t\tPerson martin = new Person(\"\\\"Bl�mel\\\" \\\"Martin\\\" \\\"19641014\\\"\");\n\t\tPerson jojo = new Person(\"\\\"Bl�mel\\\" \\\"Johannes\\\" \\\"19641014\\\"\");\n\t\tTestUser umartin = new TestUser(\"martin\");\n\t\tAssert.assertNull(ma...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test case 33: Contrast
@LargeTest public void testContrast() { TestAction ta = new TestAction(TestName.CONTRAST); runTest(ta, TestName.CONTRAST.name()); }
[ "public void contrastImage(){\r\n // YOUR CODE HERE\r\n //The following code get help from tutors\r\n for(int rows=0; rows<this.image.length; rows++){\r\n for(int cols=0; cols<this.image[0].length; cols++){\r\n int greyColor = this.image[rows][cols];\r\n if(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by Apache iBATIS ibator. This method returns the value of the database column report_column_setting.col_type
public String getColType() { return colType; }
[ "public java.lang.String getColumnType() {\n return columnType;\n }", "public String getCOL_TYPE() {\r\n return COL_TYPE;\r\n }", "@DISPID(20) //= 0x14. The runtime will prefer the VTID if present\n @VTID(43)\n String columnType();", "public Datatype getcolumnType(int index);", "public...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns whether this structured viewer is configured to use an internal map to speed up the mapping between elements and SWT items. The default implementation of this framework method checks whether the internal map has been initialized.
protected boolean usingElementMap() { return elementMap != null; }
[ "public boolean isNativeMaps() {\n return internalNative != null;\n }", "public abstract boolean isMapLoaded();", "public boolean isSetMapMap() {\n return this.mapMap != null;\n }", "public boolean isMapLoaded()\r\n {\r\n return loadedMap;\r\n }", "public boolean isSet...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Is terminal module enabled or disabled.
boolean isModuleEnabled(int module);
[ "boolean hasIsTerminal();", "private static boolean isTerminal() {\n return System.console() != null;\n }", "boolean isConsole();", "boolean isDisabled();", "boolean isExpertMode();", "public boolean isTerminal(){\n\t\tif (type == BNFSymbolType.Terminal) return true;\n\t\telse return false;\n\t}...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Open page and link page to this internal node also insert the min key of page into this one this page's size will NOT be incremented
public void add(Page<Key, Value> page) { Key minKey = page.keys.min(); keys.put(minKey, page.ref); }
[ "public Page<Key, Value> open() throws IOException, ClassNotFoundException {\n if (isOpened()) return next;\n FileInputStream fileIn = new FileInputStream(String.format(\"%s%04d.bin\", path, id));\n ObjectInputStream in = new ObjectInputStream(fileIn);\n Page<Key, Value> ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the COM value for this InsuranceINS.
public webservice.hospindex.InsuranceINSCOM[] getCOM() { return COM; }
[ "public webservice.hospindex.InsuranceINSE_COM[] getE_COM() {\n return e_COM;\n }", "public ComPort com() {\n\t\treturn com;\n\t}", "public void setCOM(webservice.hospindex.InsuranceINSCOM[] COM) {\n this.COM = COM;\n }", "public Integer getComId() {\n return comId;\n }", "publ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Specify the number of tasks to be deployed and the number of cycles each task should execute the benchmark.
public LinPackBenchmark(int tasks, int cycles) { super(); this.tasks = tasks; this.cycles = cycles; }
[ "public void test10Workers100Tasks()\n {\n commonTest( 100, 10, 1800L, 2000L, 10, true, true, -1, -1 );\n }", "public abstract int computeTotalExecutors();", "int getNumberOfTasksDeterminingBuildDuration();", "public void setTaskCount(java.lang.Integer taskCount) {\n this.taskCount = taskC...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns a numeric version of the difference of all color in HSV components.
public static float[] colorDifferenceHSV(final Color color1, final Color color2) { float[] difference = new float[3]; float[] hsb1 = Color.RGBtoHSB(color1.getRed(), color1.getGreen(), color1.getBlue(), null); float[] hsb2 = Color.RGBtoHSB(color2.getRed(), color2.getGreen(), color2.getBlue(), nu...
[ "public float hue() {\n int r = (color >> 16) & 0xFF;\n int g = (color >> 8) & 0xFF;\n int b = color & 0xFF;\n\n int V = Math.max(b, Math.max(r, g));\n int temp = Math.min(b, Math.min(r, g));\n\n float H;\n\n if (V == temp) {\n H = 0;\n } else {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__AtomicDomainSpecificEvent__Group_7_2__0" $ANTLR start "rule__AtomicDomainSpecificEvent__Group_7_2__0__Impl" ../org.gemoc.gel.xtext.ui/srcgen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:2829:1: rule__AtomicDomainSpecificEvent__Group_7_2__0__Impl : ( 'feedback' ) ;
public final void rule__AtomicDomainSpecificEvent__Group_7_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { // ../org.gemoc.gel.xtext.ui/src-gen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:2833:1: ( ( 'feedback' ) ) ...
[ "public final void rule__FeedbackRule__Group__0__Impl() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.gemoc.gel.xtext.ui/src-gen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:5323:1: ( ( () ) )\n // ../org.g...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
An edge's tail has been changed in a registered graph or one of its subgraphs. The added edge is the "source" of the event. The previous tail is accessible via e.getOldValue().
public void edgeTailChanged(GraphEvent e);
[ "public void edgeHeadChanged(GraphEvent e);", "public void nodeRemoved(GraphEvent e);", "public void graphChanged(DirectedGraph graph, IGraphDelta delta);", "public void processEdgeAdded(ProcessEdge edge);", "public void updateEdge() {\n\t}", "public void nodeAdded(GraphEvent e);", "@Override\n publi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
void marshal(org.xml.sax.ContentHandler) Sets the value of field 'paginaFuente'.
public void setPaginaFuente(java.lang.String paginaFuente) { this._paginaFuente = paginaFuente; }
[ "public java.lang.String getPaginaFuente()\r\n {\r\n return this._paginaFuente;\r\n }", "void xsetCausalePagamento(it.gov.agenziaentrate.ivaservizi.docs.xsd.fatture.v12.CausalePagamentoType causalePagamento);", "public void setFuente(String fuente) {\n this.fuente = fuente;\n }", "publi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates a passport from textual fields.
static Optional<Passport> fromFields(Map<String, String> fields) { try { return Optional.of(new PassportImpl(fields)); } catch (IllegalStateException | IllegalArgumentException e) { logger.info(e::getMessage); return Optional.empty(); } }
[ "public Password(String plainText){\n this(plainText,1);\n }", "IAntwort createAntwort(Antwort.AntwortType type);", "Text(String password)\n {\n value = password;\n }", "Account createAccount(String passphrase);", "SecureText createSecureText();", "public static PasswordField c...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Initializes the back and exit buttons's onAction events.
private void initializeButtons() { btnBack.toFront(); btnBack.setOnAction(event -> { MenuController.show(); }); }
[ "void setActionBtnBack(LinkActionGUI mainAction, LinkActionGUI linkAction);", "public void initAction() {\n\t\tclickTo=new Click();\n\t\tenterTo=new Enter();\n\t}", "private void initActions() \n {\n // Quits the application\n this.quitAction = new AbstractAction (\"Quit\") \n {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }