query
stringlengths
8
1.54M
document
stringlengths
9
312k
negatives
listlengths
19
20
metadata
dict
Creates a reference to the EditMenuController and passes in window items and other sub Controllers when necessary.
private void setupEditMenuController() { this.editMenuController = new EditMenuController(); this.editMenuController.setTabPane(this.tabPane); }
[ "private CMenu createEditMenu() {\n CMenu menu = new CMenu (\"Edit\");\n menu.add(editHandler, menuConstraints);\n return menu;\n }", "@FXML private void handleEditMenuAction(ActionEvent event) { this.editMenuController.handleEditMenuAction(event); }", "private JMenu createEditMenu() {\n\t\tJMenu edit...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
unplugging engines in reverse order of registration
@Override public void shutdown() { if (LOG.isDebugEnabled()) { LOG.debug("stopping broker by unplugging engines in reverse order"); } // iterate over all broker engines in reverse order List<BrokerEngine> engines = broker.getEngines(); ListIterator<BrokerEngine> lit = engines.listIterator(e...
[ "@Generated\n @Selector(\"unregisterFromEngine\")\n public native void unregisterFromEngine();", "public void uniregisterServices() \n\t{\n\t\t((DataFieldMonitor)bundleMonitors.get(3)).unregisterWeavingService();\n\t}", "protected void uninstallComponents() {\n\t}", "protected void uninstallComponents()...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Converts input stream into UTF8 formatted text.
public static String inputToUTF8(InputStream input) { try { return org.apache.commons.io.IOUtils.toString(input, "UTF-8"); } catch (IOException | NullPointerException e) { return ""; } }
[ "public String toUTF8(String input) throws IOException;", "public void convertToUTF8() {\n FileInputStream istream = null;\n Writer out = null;\n try {\n istream = new FileInputStream(path);\n BufferedInputStream in = new BufferedInputStream(istream);\n Charse...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Spring Data ElasticSearch repository for the Medication entity.
public interface MedicationSearchRepository extends ElasticsearchRepository<Medication, Long> { }
[ "public interface MedCheckDetSearchRepository extends ElasticsearchRepository<MedCheckDet, Long> {\n}", "public interface TypeMedicationSearchRepository extends ElasticsearchRepository<TypeMedication, Long> {\n}", "public interface MedicalCaseSearchRepository extends ElasticsearchRepository<MedicalCase, Long> {...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets if this node is assumed to be connected to a core node (core nodes are not in the design)
public void setIsConnectedToNetworkCore (boolean isConnectedToCore) { n.setAttribute(ATTNAMECOMMONPREFIX + ATTNAMESUFFIX_ISCONNECTEDTOCORE , new Boolean (isConnectedToCore).toString()); }
[ "public boolean isConnectedToNetworkCore () { return getAttributeAsBooleanOrDefault(ATTNAMECOMMONPREFIX +ATTNAMESUFFIX_ISCONNECTEDTOCORE , WNetConstants.WNODE_DEFAULT_ISCONNECTEDTOCORE); }", "public void setCore(AbstractCore core) {\n this.coreLocation = new Location(core);\n }", "public void setCPUCo...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
The MyCBWithEqualValues default constructor.
public MyCBWithEqualValues(){ setLayout(new BorderLayout()); final DefaultComboBoxModel<TlcStringItem> model = new DefaultComboBoxModel<>(); final JComboBox jcb = new JComboBox(model); model.addElement(new TlcStringItem("hoje")); model.addElement(new TlcStringItem("hoje")); model.addElement(new...
[ "public WSEjbBnd() {\n this(null, Common.USE_DEFAULT_VALUES);\n }", "@Test\n public void testConstructArgumentsByValue() {\n System.out.println(\"constructArgumentsByValue\");\n AbstractJssComboAction instance = new AbstractJssComboActionImpl();\n Map notExpResult = null;\n Map result = ins...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Check if this component is acyclic.
public final boolean isAcyclic() { return this.topologicalSort().size() == this.sizeNodes(); }
[ "public boolean isCyclicRelationship() {\n return cyclicRelationship;\n }", "public boolean isConnectible() {\r\n return entity != null && entity instanceof Connectible;\r\n }", "public boolean isConnected() {\n return this == CONNECTED || this == CONNECTEDREADONLY;\n }", ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the map type. Call this method inside ajax request when the map itself is not added to the target.
public void setMapType(final GMapType mapType, final AjaxRequestTarget target) { setMapType(mapType); target.appendJavaScript(mapType.getJSsetMapType(GMap.this)); }
[ "private final native void setMapType(int type) /*-{\r\n\t\tthis.setMapType(type);\r\n\t}-*/;", "public void setMapType(MapType mapType) {\n InfoWindowOptionsImpl.impl.setMapType(super.options, mapType);\n }", "public final native void setMapType(String mapTypeId) /*-{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tthi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "DEFAULTOUTPUT" $ANTLR start "DEBUGMODE"
public final void mDEBUGMODE() throws RecognitionException { try { int _type = DEBUGMODE; int _channel = DEFAULT_TOKEN_CHANNEL; // C:\\work\\art\\latest-code\\vclang-code-dd0a89f0d579f02ec8c3d8cd398ea8f7cbb445aa\\src\\art\\grammar\\expression.g:134:11: ( 'debugmode' ) ...
[ "public final void debug_directive() throws RecognitionException {\n try {\n // D:\\\\decomplier_tools\\\\smali\\\\smali\\\\smali\\\\src\\\\main\\\\antlr3\\\\smaliTreeWalker.g:587:3: ( line | local | end_local | restart_local | prologue | epilogue | source )\n int alt23 = 7;\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Set the ViewPlatform's activation radius
void setActivationRadius(float activationRadius) { sphere.setRadius(activationRadius); if (source != null && source.isLive()) { repaint(); } // Notify behavior scheduler & RenderBin if (source.isLive()) { J3dMessage message = new J3dMessage(); message.type = J3dMessage.UPDATE_VIEWPLATFORM; mes...
[ "float getActivationRadius() {\n return (float) sphere.getRadius();\n }", "public void setRadius(double r){radius = r;}", "public void setRadius(double r) {\n this.radius = r;\n }", "boolean getUseHostRadiusOverride();", "public void setRadius(double d) {radius=d;}", "public void setRa...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
optional string execId = 115;
public String getExecId() { Object ref = execId_; if (!(ref instanceof String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; String s = bs.toStringUtf8(); if (bs.isValidUtf8()) { execId_ = s; } ret...
[ "String getExecId();", "public Builder setExecId(\n String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00004000;\n execId_ = value;\n onChanged();\n return this;\n }", "String getExecRefId();", "public String getExecI...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Centers the model so it evenly spaced over (0,0,0) Note: this will change all the XYZ points in the model
public void centreModel(){ centreModel(modOffset); }
[ "public void centreModel(gb_Vector3 offset){\n\t\tfor(int i = 0; i < point.length; i++)\n\t\t\tpoint[i].sub(offset);\n\t\tmodOffset = new gb_Vector3();\n\t}", "public void centerCommand()\n {\n Mesh theMesh = (Mesh) getObject().getObject();\n MeshVertex vert[] = theMesh.getVertices();\n MeshViewer view ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the value for child leaf "txbuffersize", using Java primitive values.
public void setTxBufferSizeValue(long txBufferSizeValue) throws JNCException { setTxBufferSizeValue(new YangUInt32(txBufferSizeValue)); }
[ "public void setTxBufferSizeValue(YangUInt32 txBufferSizeValue)\n throws JNCException {\n setLeafValue(Epc.NAMESPACE,\n \"tx-buffer-size\",\n txBufferSizeValue,\n childrenNames());\n }", "public void addTxBufferSize() throws JNCException {\n setLeafValu...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Getter method for the COM property "DisplayContextTooltips"
@VTID(145) boolean getDisplayContextTooltips();
[ "@VTID(143)\r\n boolean getDisplayMemberPropertyTooltips();", "public TooltipDisplay getTooltipDisplay();", "java.lang.String getTooltip();", "final public boolean isTooltipsVisible()\n {\n return ComponentUtils.resolveBoolean(getProperty(TOOLTIPS_VISIBLE_KEY), true);\n }", "String getTooltip();", "...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
renames the files and puts them into a new directory
public String renameFilesInDirectory(String Path, ArrayList<String> newNameList) throws IOException, InterruptedException { File folder = new File(Path); File[] listOfFiles = folder.listFiles(); new File(Path + "newNames").mkdir(); int pdfNamePositionCounter = 0; sortByNumber(listOfFiles); //sorts...
[ "public static void initialRenaming() throws IOException{\r\n File dir = new File(\".\\\\images\");\r\n if (!dir.exists()){\r\n dir.mkdir();\r\n }\r\n for (File file : dir.listFiles()){\r\n String type = FilenameUtils.getExtension(file.getPath());\r\n \r\n if(type...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns all the products with the count of transactions on each one
public ArrayList<Product> getProductsWithCount(){ ArrayList<Product> products = new ArrayList<>(); for(Product product : storage.keySet()){ product.setNumberOfTransactions(storage.get(product).size()); products.add(product); } return products; }
[ "int getTotalProductCount();", "int getProductCount();", "public List<Transaction> getTransactionCount();", "public int getTotalProducts(){\n return inventoryList.size()+shoppingList.size()+ requirementsList.size();\n }", "long countNumberOfProductsInDatabase();", "public int countByNumberOfProd...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Used for stop recording. and feature can do some thing by it implement.
void stopRecording();
[ "public void stopRecording();", "public void stop() {\r\n\t\tisRecording = false;\r\n\t}", "public void StopRecording()\n {\n handler.stopRecording();\n\n }", "public void stopRecording() {\r\n\t\tSwingUtilities.invokeLater(new Runnable() {\r\n\t\t\tpublic void run() {\r\n\t\t\t\tfinish();\r\n\t\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
get MySql DB connection using connection parameters
public static Connection getMySqlDBConnection(){ System.out.println("MySQL Connection success"); return null; }
[ "private Connection getConn_MySql() {\n\n String url = \"jdbc:mysql://\" + dd.host + \":\" + dd.port + \"/\";\n String driver = \"com.mysql.jdbc.Driver\";\n System.out.println(\"getConn_MySql: url:\" + url + \" user: \" + dd.username + \" driver: \" + driver);\n\n Connection conn = null;\n try {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Provides a new instance of the desired component type. After use this instance should be released to allow
<T extends Component> T createComponent(Class<T> componentClass);
[ "ComponentType createComponentType();", "Component createComponent();", "ComponentsType createComponentsType();", "public Component newComponent()\r\n {\r\n Model model = getModel();\r\n try\r\n {\r\n return m_controller.createComponent( model );\r\n }\r\n catc...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Retrieves a list of all belonging to the current user Each request returned does not include a full copy of the RequestFile, only the metadata of the file is populated. This is to conserve bandwidth by not sending the potentially large file contents for each request. The file contents can be retrieved by using FileCont...
@RequestMapping(value="/mine/all", method= RequestMethod.GET, produces={MediaType.APPLICATION_JSON_VALUE}) public @ResponseBody List<Request> getAllMyRequests() { return requestManager.getAllRequestsByUser(getCurrentUser().getId()); }
[ "public List<User> getUsersWithRequests();", "public User[] getMyRequestedInUsers() {\n List<FullUser> inUserRequestList;\n\n try {\n inUserRequestList = baseRepository.<FullUser>edgeRequestQueries().getToEdgeRequests(this.getUsername(), EdgeRequestQueries.CREATOR.TO);\n } catch (I...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the groups of the listed AvailableProcesses
public List<String> obtemAvailableProcesses(List<String> selectedValuesList) { List<String> grupo = new LinkedList<>(); for (Object item : selectedValuesList) { grupo.addAll(AvailableProcesses.stream().filter(d -> d.name().equals(item.toString())).map(d -> d.getGrupo()).flatMap(x -> x.stream()).collect(Colle...
[ "String[] getAvailableGroups();", "public List<String> getProcesses() throws CallError, InterruptedException {\n return (List<String>) service.call(\"getProcesses\").get();\n }", "List<ConanProcess> getProcesses();", "List<String> getGroups();", "public static List<String> getConfigGroups()\n {...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Starts the reset timer. After the timer fires, the program will present the start controller.
private void startResetTimer() { if (this.resetTimer == null) { int delay = Configuration.getInstance().getResetTimeout(); this.resetTimer = new Timer(delay, new ActionListener() { @Override public void actionPerformed(ActionEvent arg0) { stopResetTimer(); MainController mainController ...
[ "public void start(){\r\n\t\t// start the timer\r\n\t\tlcdTimer.start();\r\n\t}", "public void start() {timer.start();}", "public void start() {\r\n if (ticks != 0) {\r\n if (uiCreator.isPresent()) {\r\n uiCreator.get().createUI(simulator);\r\n } else {\r\n simulator.start();\r\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Run the FrameMotionListener(JInternalFrame) constructor test.
@Test public void testFrameMotionListener_1() throws Exception { JInternalFrame f = new JInternalFrame(); FrameMotionListener result = new FrameMotionListener(f); // add additional test code here assertNotNull(result); }
[ "@Test\n public void testInitializeFrameImpl() {\n Frame frame = new FrameImpl(1, new Ellipse(new PosnImpl(20, 20), 20, 20, Color.BLUE));\n\n // Some basic sanity checks to ensure that it initialized properly\n assertEquals(1.0, frame.getTime(), 0.01);\n assertEquals(new PosnImpl(20, 20), frame.getShap...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Set true if the component should show a default caption (csscode for the currently selected color, e.g. ffffff) when no other caption is available.
public void setDefaultCaptionEnabled(boolean enabled) { getState().showDefaultCaption = enabled; }
[ "public boolean isDefaultCaptionEnabled() {\n return getState(false).showDefaultCaption;\n }", "public void setCaption(String caption) {\n if (highlightCaption) {\n captionLabel.setStylePrimaryName(\"ode-Box-header-caption-highlighted\");\n captionAlreadySeen = false;\n }\n captionLab...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Costruttore pubblico di StringEstesa
public StringEstesa() {}
[ "String getAnnoPubblicazione();", "public java.lang.String getMsgPublicado();", "public String getStringObjetos()\n {\n String aDevolver=\"\";\n ArrayList<String> elementosQueHay = getDescripcionElementos();\n if(elementosQueHay.size()==0)\n {\n aDevolver = \"En esta ha...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ Suma un dia, este metodo sirve de apoyo a sumaNDias
private Fecha suma1Dia() { this.dias++; if (this.dias > diasMes(this.meses, this.anyos)) { this.dias = 1; this.meses++; if (this.meses > 12) { this.meses = 1; this.anyos++; } } return this; }
[ "public void adicionaDoisDias(){\n Calendar calendario = Calendar.getInstance();\r\n int j=0;\r\n for(Item livro:item){\r\n if(j!=0){\r\n calendario.setTime(livro.getDataDevolucao());\r\n calendario.add(Calendar.DATE, 2);\r\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the result of interpreting the object as an instance of 'Processor'. This implementation returns null; returning a nonnull result will terminate the switch.
public T caseProcessor(Processor object) { return null; }
[ "public Processor getProcessor() {\n return processor;\n }", "public Object caseHwProcessor(HwProcessor object) {\r\n\t\treturn null;\r\n\t}", "public EntryProcessor getProcessor()\n {\n return m_processor;\n }", "public abstract Parts getProcessor();", "public int getProcesso...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Hash function for the subscriber based on the String implementation of the hashCode() function
public int hashCode() { return ("Subscriber$" + getAddress().getHostAddress() + ":" + getPort()).hashCode(); }
[ "java.lang.String getHash();", "public int hashCode() {\n\t\treturn hashString.hashCode();\n\t}", "public String computeHash(String s);", "@Override\n\tpublic int hashCode() {\n\t\tint hash = 5;\n\t\thash += this.name.hashCode() * 7;\n\t\thash += this.delay * 11;\n\t\treturn hash;\n\t}", "public int hashCod...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method implements the onChange listener of the Opacity slider and the Text's ListBoxes
public void onChange(Widget sender) { /** if there was a change in opacity, we update the currentFillColor and the selected object if there's any. */ if (sender.equals(this.fillOpacity)) { int value = this.fillOpacity.getValue(); if (this.curr_obj != null) { final Color color = this.curr_obj.g...
[ "private void createSlider(Composite parent){\n\t\tComposite container = new Composite(parent, SWT.NONE);\n\t\tcontainer.setLayout(new GridLayout(3,false));\n\t\tcontainer.setLayoutData(new GridData(GridData.FILL_BOTH));\n\t\tnew Label(container, SWT.NONE).setText(Messages.ColorDialog_transparencyLabel);\n\t\talpha...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the attribute value for LocationCode, using the alias name LocationCode.
public String getLocationCode() { return (String)getAttributeInternal(LOCATIONCODE); }
[ "public String getLocationCode() {\n return normalizedBic.substring(LOCATION_CODE_INDEX, LOCATION_CODE_INDEX + LOCATION_CODE_LENGTH);\n }", "public String getLookupCode() {\n return (String)getAttributeInternal(LOOKUPCODE);\n }", "LocationModel findLocation(final String code);", "public fi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
returns a set of event DTOs with every event from the requested user mail throws a ResourceNotFoundException if there are no events by the requested user
public Set<EventTO> getAllEventsByUser(String mail) { LOGGER.trace("trying to get all events from user {}", mail); BusinessUser user = businessUserService.getBusinessUser(mail); int id = user.getId(); Set<Event> events = eventRepository.findAllByUserId(user); if (!(events.isEmp...
[ "private void getEvents()\n {\n URLConnection http = new URLConnection();\n try\n {\n eventsForUser = http.sendGetEventsForUser(thisUser.getEmail());\n } catch(IOException e)\n {\n Toast.makeText(getActivity().getApplicationContext(), \"No Events for User\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the inertia logical block.
public Inertia getInertiaBlock() { return inertia; }
[ "public Block getBlock(){\n return block;\n }", "public float getInertia () {\n\t\treturn body.getInertia();\n\t}", "public Block getLeverBlock() {\r\n \t\treturn this.getWorld().getBlockAt(this.getLeverLocation());\r\n \t}", "public Block getBlock() {\n return block;\n }", "Block getInn...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the table metadata.
Table getTableMetadata(String table);
[ "com.scalar.db.rpc.TableMetadata getTableMetadata();", "com.scalar.db.rpc.TableMetadataOrBuilder getTableMetadataOrBuilder();", "private ResultSetMetaData getMetadata(final String table) throws SQLException {\r\n // the logger logs entering this method\r\n logger.entering(\"org.electrocodeogram.mo...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Crea un singolo addebito.
private int creaSingoloAddebito(int cod, Date data) { /* variabili e costanti locali di lavoro */ int nuovoRecord = 0; boolean continua; Dati dati; int codConto = 0; int codListino = 0; int quantita = 0; double prezzo = 0.0; Campo campoConto = null...
[ "public void creaAddebiti(Date dataInizio, Date dataFine, ArrayList<Integer> codiciConto) {\n /* variabili e costanti locali di lavoro */\n boolean continua;\n Date dataCorr;\n Modulo modulo;\n Navigatore nav;\n ProgressBar pb;\n OpAddebiti operazione;\n\n try...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
String[] posList = tokens[1].split(" "); int posCount = posList.length 1; //since the term is also in the array docData.addBodyHit(tokens[1]); posList[0], posCount);
public void addBodyHit(String Line ) { String[] posList = Line.split(" "); String term = posList[0]; int posCount = posList.length - 1; bodyHitMap.put(term, posCount); ArrayList<Integer> HitPos = new ArrayList<Integer>(); for(int i = 1;i < posList.length;i++) HitPos.add(Integer.parseInt(posList...
[ "public HashMap<String,Integer> getPosAtSentenceStart(String taggedtext){\n String pos = \"\";\n StringTokenizer sentences = new StringTokenizer(taggedtext,\".;:?!\");\n while(sentences.hasMoreTokens()){\n String sentence = sentences.nextToken();\n StringTokenizer tokens =...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Metodo auxiliar que toma el nodo ret enviado por parametro y crea el camino, en una lista, desde la raiz hasta el
private List<Node<T>> completaCamino(Node<T> ret, List<Node<T>> camino) { boolean comp = true;// Comprobacion camino.add(ret);// Aņadimos el nodo al camino while (comp) { if (ret.getParent() != null) {// Mientras no sea la raiz camino.add(ret.getParent(), 1);// Aņade al inicio de la lista ret = r...
[ "public void crearLibro(String titulo, String autor, String fechaPublicacion, int numeroPaginas, String idioma, String tema,ListaEnlazada listacodigo, ListaEnlazada listatitulo,ListaEnlazada listaautor){\n Texto libro=new Texto(titulo, autor, fechaPublicacion, numeroPaginas, idioma, tema);\n Nodo no...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Proper constructor for jobs, passing in jobID and Runtime.
public Job(String JobID, int RunTime) { this.JobID = JobID; this.RunTime = RunTime; }
[ "public Job() {\n\t\t\t\n\t\t}", "public Job() {\r\n\t\tSystem.out.println(\"Constructor\");\r\n\t}", "public JobResource()\r\n {\r\n }", "public schedulerJob() {\n }", "public CmdCallJob() {\n\t\t}", "public JobManager(){\n //Initialize the job manager for use of the system\n }", "pu...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test case number: 40 / 3 covered goals: Goal 1. org.objectweb.cjdbc.driver.ResultSetMetaData.(Lorg/objectweb/cjdbc/driver/DriverResultSet;)V: rootBranch Goal 2. org.objectweb.cjdbc.driver.ResultSetMetaData.getTableName(I)Ljava/lang/String;: I4 Branch 25 IF_ICMPLT L183 false Goal 3. org.objectweb.cjdbc.driver.ResultSetM...
@Test(timeout=300000) public void test40() throws Throwable { Field[] fieldArray0 = new Field[0]; DatabaseProcedure databaseProcedure0 = new DatabaseProcedure("", "--%M--%z", 2632); ArrayList arrayList0 = databaseProcedure0.getParameters(); DriverResultSet driverResultSet0 = new DriverResult...
[ "@Test(timeout=300000)\n public void test38() throws Throwable {\n Field[] fieldArray0 = new Field[1];\n DatabaseTable databaseTable0 = new DatabaseTable(\"\", 3463);\n ArrayList arrayList0 = databaseTable0.getColumns();\n DriverResultSet driverResultSet0 = new DriverResultSet(fieldArray0, (A...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Descriptor for a mapping (XML) file.
public interface FileDescriptor { /** * The mapping file name. This is its name within the archive, the * expectation being that most times this will equate to a "classpath * lookup resource name". * * @return The mapping file resource name. */ public String getName(); /** * Retrieves access to the I...
[ "public String getMappingFilePath();", "public File getMappingsFile() {\n return theMappingsFile;\n }", "protected FileBasedElementMapping() {\n\t}", "public PersistenceManagerXmlImpl(String descriptorPath, String mappingPath) {\n this.descriptorPath = descriptorPath;\n this.mappingPath = ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the status of the game's need for panning
public boolean getPanStatus() { return doPan; }
[ "int getGameStatus();", "@JSProperty(\"panning\")\n boolean getPanning();", "private boolean canMove() {\n\t\tif (System.currentTimeMillis() - lastTrunTime < 300) {// move time is\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// 300ms before\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// last move\n\t\t\treturn false;\n\t\t}\n\t\tboo...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Checks whether position resides in a default (X10) partition of document.
private static boolean isDefaultPartition(IDocument document, int position, String partitioning) { doAssert(position >= 0); doAssert(position <= document.getLength()); try { ITypedRegion region= TextUtilities.getPartition(document, partitioning, position, false); return r...
[ "public boolean hasDefaultPosition( ) {\n\n return ( defaultX != Integer.MIN_VALUE ) && ( defaultY != Integer.MIN_VALUE );\n }", "public boolean hasDefaultInitialPosition( ) {\r\n\r\n return scene.hasDefaultPosition( );\r\n }", "public boolean isSetPositionX() {\r\n return EncodingUtils...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the _ position.
public int get_Position() { return this.position; }
[ "public int position() {\n return pos;\n }", "public String getPosition(){\r\n\t\treturn position;\r\n\t}", "public int getPosition ()\r\n {\r\n return (getCursor ().getPosition ());\r\n }", "public java.lang.Integer getPos() {\n return pos;\n }", "public java.lang.Integer get...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Instantiates and initializes a CachingEntityResolver that maintains a perpetual inmemory cache for all entities resolved from the given allowed domains.
public CachingEntityResolver(String ... allowedDomains) { this.allowedDomains = Arrays.asList(allowedDomains); this.cachedSchemas = new HashMap<>(); }
[ "private void initEntityResolver() {\n final String entityResolveClazzName = System.getProperty( XmlPackageReader.ENTITY_RESOLVER_PROPERTY_NAME );\n if ( entityResolveClazzName != null && entityResolveClazzName.length() > 0 ) {\n try {\n final Class entityResolverClazz = Thre...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Tests if the checkValidity method works on a valid deck
@Test public void checkValidityTest1() { GenericStandardDeckGame g = new GenericStandardDeckGame(); assert (g.checkValidity(g.getDeck())); }
[ "@Test\n public void checkValidityTest2() {\n GenericStandardDeckGame g = new GenericStandardDeckGame();\n List<Card> deck = g.getDeck();\n deck.set(32, new Card(Card.number.four, Card.suit.club));\n assert (!g.checkValidity(deck));\n }", "public boolean checkDeck(List<Card> deck) {\n Set<Card> s...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Retrieves an array of PersonellBean using the relation table Contract given a SampletypeBean object.
public PersonellBean[] loadPersonellViaContract(SampletypeBean pObject) throws SQLException { Connection c = null; PreparedStatement ps = null; String strSQL = " SELECT " + " *" + " FROM " + " p...
[ "public ContractBean[] loadContractViaContractsampletype(SampletypeBean pObject) throws SQLException\n {\n Connection c = null;\n PreparedStatement ps = null;\n String strSQL = \" SELECT \"\n + \" *\"\n + \" FROM \"\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This SportsCard constructor calls the superclass constructor and initializes the 'game' field with the String "Baseball."
public SportsCard(){ super("Baseball"); }
[ "public BaseballCard(){\r\n\r\n\t}", "public PlayingCard() { //default ctor - same name as class, no parameters, no return type\n cardValue = 1;\n cardSuit = \"Spades\";\n cardColor = \"Black\";\n cardShape = \"Rectangle\";\n cardSymbol = \"A\";\n isFaceUp = true;\n }"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the value of the referencia property.
public int getReferencia() { return referencia; }
[ "public java.lang.String getReferencia() {\n return referencia;\n }", "public String getDesReferencia() {\r\n return desReferencia;\r\n }", "public java.lang.String getReferenciado();", "public int getAnoReferencia() {\n return anoReferencia;\n }", "public String getNumeroRefer...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the list lang dto.
public void setListLangDTO(List<LanguageDTO> listLangDTO) { this.listLangDTO = listLangDTO; }
[ "public List<LanguageDTO> getListLangDTO() {\r\n\t\treturn listLangDTO;\r\n\t}", "public void setLanguageList(Language[] languageList) {\n this.languageList = languageList;\n }", "void setLang(java.lang.String lang);", "public Builder setLanguageList(in.trujobs.proto.PreScreenLanguageObject value) {...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Constructs a new DAOException exception with the specified detail message.
public DAOException(String message) { super(message); }
[ "public DAOException(String message)\r\n {\r\n super(message);\r\n }", "public DAOException(String message, String... params)\r\n {\r\n super(message, params);\r\n }", "public DatabaseException( final String message ) {\n\t\tsuper( message );\n\t}", "public DAOException() {\n\t}", "public DAOUpdateExce...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Puts content local value and return fluid builder.
public ContentBuilder putLocalValue(String name, Object value) { if (name != null && value != null) { local.put(name, value); } return this; }
[ "Builder addContentLocation(Place.Builder value);", "Builder addContentLocation(String value);", "public static Builder<?> builder(FluidStack fluid) {\n return simpleBuilder(conditions -> new SetFluidLootFunction(conditions, fluid));\n }", "public com.babbler.ws.io.avro.model.BabbleValue.Builder setConten...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Perform a boolean branch operation based on the Ruby "true" value of the top value on the stack. If Ruby "true", invoke the true branch callback. Otherwise, invoke the false branch callback.
public void performBooleanBranch(BranchCallback trueBranch, BranchCallback falseBranch);
[ "public void performBooleanLoopLight(BranchCallback condition, BranchCallback body, boolean checkFirst);", "public void performBooleanLoop(BranchCallback condition, BranchCallback body, boolean checkFirst);", "public void performBooleanLoopSafe(BranchCallback condition, BranchCallback body, boolean checkFirst);...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
The method introspects the target object, finding read/write properties, and tests the getter and setter.
public static void assertGetterSetterBehavior(Object target) { try { BeanInfo beanInfo = Introspector.getBeanInfo(target.getClass()); PropertyDescriptor[] descriptors = beanInfo.getPropertyDescriptors(); for (PropertyDescriptor descriptor : descriptors) { if (descriptor.getW...
[ "boolean usePropertyAccess();", "@Override\n public void introspect(final IntrospectionContext icontext)\n throws IntrospectionException {\n for (final Method m : icontext.getTargetClass().getMethods()) {\n if (m.getName().startsWith(getWriteMethodPrefix())) {\n fina...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This is called with system output, to both make a log within the report and add prefix (e.g.'[SYS]') beforehand, with extra options: [1. Custom LogStatus] [2. forceLogEntry if debug mode is off]
public static void logsysout(String sysout, LogStatus status, Boolean forceLogEntry) { // Print caller class if error if (status == LogStatus.ERROR || status == LogStatus.FATAL) sysout = sysout + System.lineSeparator() + "<br><sub>*" + getCallerClassName() + "*</sub> " + currentSysOutLink; ...
[ "public void logSystemInfo(boolean incremental) {\n final String inc = incremental ? \" (incremental)\" : \"\";\n core_.logMessage(\"***** BEGIN Problem Report System Info\" + inc + \" *****\");\n SystemInfo.dumpAllToCoreLog(!incremental);\n core_.logMessage(\"***** END Problem Report System Inf...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Saves changes. Let JSF run /views/packageEditPage.jsp on POST /server/packages/edit/[id] request. On errors let JSF run /views/newPackage.jsp on POST /server/packages/add request. Otherwise creates new package and redirects to list of packages.
@RequestMapping(value = "/edit", method = RequestMethod.POST) public String saveEdit (@ModelAttribute("pack") Package pack, @RequestParam(value="id", required=true) Integer id, Model model) { logger.debug("Received request to update package"); PackageDao pd = null; try { ApplicationContext ...
[ "@RequestMapping(value = \"/add\",method = RequestMethod.POST)\n \tpublic String addPackage (@RequestParam(value=\"id\", required=true) Integer programId, \n \t\t\t@Valid@ModelAttribute(value=\"pack\") Package pack, BindingResult result, Model model) {\n \t\t(new PackageValidator ()).validate (pack, result);\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
The descriptive name of the TLS inspection configuration. You can't change the name of a TLS inspection configuration after you create it.
public String getTLSInspectionConfigurationName() { return this.tLSInspectionConfigurationName; }
[ "public void setTLSInspectionConfigurationName(String tLSInspectionConfigurationName) {\n this.tLSInspectionConfigurationName = tLSInspectionConfigurationName;\n }", "public String getTLSInspectionConfigurationId() {\n return this.tLSInspectionConfigurationId;\n }", "String getConfigName();"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the proxy port number
public Integer getProxyPort();
[ "int getRemoteProxyPort();", "int getHttpProxyPort();", "public int getHttpProxyPort();", "public int getPort() {\n\t\treturn StringUtil.getInt(proxyPort, 0);\n\t}", "public final String getProxyPort() {\n return properties.get(PROXY_PORT_PROPERTY);\n }", "public int HTTPproxyPort();", "public int g...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ Search one of the meta tables (ROOT or .META.) for the HRegionLocation info that contains the table and row we're seeking.
private HRegionLocation locateRegionInMeta(final byte [] parentTable, final byte [] tableName, final byte [] row, boolean useCache, Object regionLockObject, boolean retry) throws IOException { HRegionLocation location; // If we are supposed to be using the cache, look in the cache to see if ...
[ "@Override\n public HRegionLocation getTableRegionLocation(byte[] tableName, byte[] row) throws SQLException {\n int retryCount = 0, maxRetryCount = 1;\n while (true) {\n TableName table = TableName.valueOf(tableName);\n try {\n return connection.getRegionLocato...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Adds the given filter to the idParams edition editor.
public void addFilterToIdParams(ViewerFilter filter);
[ "public void addFilterToIdAttrs(ViewerFilter filter);", "public void addBusinessFilterToIdParams(ViewerFilter filter);", "public void addFilterToCreator(ViewerFilter filter);", "public void addFilterToReader(ViewerFilter filter);", "public void addFilterToAnotations(ViewerFilter filter);", "public void ad...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
comparator, nulls lower (messageType) //
public JwComparator<AcMessageMapping> getMessageTypeComparatorNullsLower() { return MessageTypeComparatorNullsLower; }
[ "public JwComparator<AcFossWebServiceMessage> getMessageComparatorNullsLower()\n {\n return MessageComparatorNullsLower;\n }", "public JwComparator<AcCandidateRouteAnalysisRequest> getMessageComparatorNullsLower()\n {\n return MessageComparatorNullsLower;\n }", "public JwComparator<AcM...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates a new HunspellDictionary containing the information read from the provided InputStreams to hunspell affix and dictionary files. You have to close the provided InputStreams yourself.
public HunspellDictionary(InputStream affix, List<InputStream> dictionaries, Version version, boolean ignoreCase) throws IOException, ParseException { this.version = version; this.ignoreCase = ignoreCase; String encoding = getDictionaryEncoding(affix); CharsetDecoder decoder = getJavaEncoding(encoding);...
[ "public HunspellDictionary(InputStream affix, InputStream dictionary, Version version, boolean ignoreCase) throws IOException, ParseException {\n this(affix, Arrays.asList(dictionary), version, ignoreCase);\n }", "public HunspellDictionary(InputStream affix, InputStream dictionary, Version version) throws IOE...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Calculates and gets a text position for the specified text render and the location. The result is represented with org.zaval.port.j2me.Point class where x field defines a row and y field defines a column.
public static Point getTextRowColAt(LwTextRender render, int x, int y) { int size = render.getTextModel().getSize(); if (size == 0) return null; int lineHeight = render.getLineHeight(); int lineIndent = render.getLineIndent(); int lineNumber = (y<0)?0:(y + lineIndent)/(lineHeight + lineInd...
[ "public static Point getTextLocationAt(LwTextRender render, PosController pos)\n {\n if (pos.getOffset() < 0) return null;\n int cl = pos.getCurrentLine();\n return new Point(render.substrWidth(render.getLine(cl), 0, pos.getCurrentCol()),\n cl * (render.getLineHeight() + render.ge...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets a list of all artifacts in play belonging to this player.
public List<Artifact> getArtifacts() { List<Artifact> artifacts = new LinkedList<Artifact>(); for(Permanent permanent : permanentsInPlay) { if(permanent instanceof Artifact) { artifacts.add((Artifact)permanent); } } return artifacts; }
[ "public List<Artifact> getArtifacts() {\n return artifacts;\n }", "public List<Artifact> getArtifacts() {\n return artifacts;\n }", "public Collection<DownloadableArtifacts.FullAndPartURIs> artifacts() {\n isArtifactSetConsumed = true;\n return Collections.unmodifiableCollection(arti...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Optional. The Google Cloud Platform Service Account to be used by the workloads. If a service account is not specified, the "default" Compute Engine service account is used. Cannot be updated. string service_account = 7 [(.google.api.field_behavior) = OPTIONAL];
@java.lang.Override public com.google.protobuf.ByteString getServiceAccountBytes() { java.lang.Object ref = serviceAccount_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); serviceAccount_ = b;...
[ "public java.lang.String getServiceAccount() {\n java.lang.Object ref = serviceAccount_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n serviceAccount_ = s;\n re...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
always returns True as objects cannot be thrown through it
public boolean blocksThrownObjects() { return true; }
[ "@Override\n\tpublic boolean validObject() {\n\t\treturn valid;\n\t}", "public static boolean _isobject(Object _obj) throws Exception{\nif (true) return _istypeof(_obj,\"object\");\n //BA.debugLineNum = 70;BA.debugLine=\"End Sub\";\nreturn false;\n}", "protected boolean shouldThrowReflectiveCopyException() \n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Enables messages of the given type to be sent to the registered receivers.
public void switchOn(Class<?> messageType) { if (messageType == null) return; // no good parameter MLink tmp = linkOf(messageType); // buffer the link to the msgType if (tmp == null) return; // type not registered, return tmp.isOn = true; // well, go on and distribute }
[ "private void sendMessageToAllTool(String receiverType) {\n presenter.presentSendMessageToAllContentInstruction();\n String content = sc.nextLine();\n boolean success;\n if (!content.equals(\"0\")) {\n success = mm.sendAll(content, gate, accountManager.getAllUsers(), receiverT...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__ExternalLoad__Group__4__Impl" $ANTLR start "rule__ExternalLoad__Group__5" ../uk.ac.kcl.inf.robotics.rigid_bodies.ui/srcgen/uk/ac/kcl/inf/robotics/ui/contentassist/antlr/internal/InternalRigidBodies.g:7684:1: rule__ExternalLoad__Group__5 : rule__ExternalLoad__Group__5__Impl rule__ExternalLoad__Group__6...
public final void rule__ExternalLoad__Group__5() throws RecognitionException { int stackSize = keepStackSize(); try { // ../uk.ac.kcl.inf.robotics.rigid_bodies.ui/src-gen/uk/ac/kcl/inf/robotics/ui/contentassist/antlr/internal/InternalRigidBodies.g:7688:1: ( rule__ExternalLoad...
[ "public final void rule__ExternalLoad__Group__4() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../uk.ac.kcl.inf.robotics.rigid_bodies.ui/src-gen/uk/ac/kcl/inf/robotics/ui/contentassist/antlr/internal/InternalRigidBodies.g:7659:1: ( rule__...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Asserts four regularlynamed components of each type: one Activity, one Service, one Provider, and one Receiver.
private void assertOneComponentOfEachType(String template, Package p) { String packageName = p.packageName; assertEquals(1, p.activities.size()); assertComponent(String.format(template, "Activity"), packageName, 0 /* intents */, p.activities.get(0)); assertEquals(1, p.se...
[ "@Test\n public void componentsExpectations() {\n // then\n assertNotNull(api.getComponents());\n assertNotNull(api.getComponents().getMessages());\n assertNotNull(api.getComponents().getSchemas());\n assertNotNull(api.getComponents().getSecuritySchemes());\n assertNotNull(api.getComponents().get...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates an empty DocumentFragment object.
@Function DocumentFragment createDocumentFragment();
[ "public DocumentFragment createDocumentFragment();", "public static org.w3c.dom.Document createEmptyDocument()\n {\n Node document = new Node(Node.ROOT_NODE, new byte[0], 0, 0);\n Node node = new Node(Node.START_TAG, new byte[0], 0, 0, \"html\",\n new TagTable());\n\n if (docume...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the end frame for this model.
public void setEndFrame(int n) { VideoClip clip = trackerPanel.getPlayer().getVideoClip(); int end = clip.getLastFrameNumber(); n = Math.max(n, 0); // not less than zero n = Math.max(n, getStartFrame()); // not less than startFrame if (n == getEndFrame()) return; endFrame...
[ "public void setEndFrameNum(int end) {\n\t\tendFrameNum = end;\n\t}", "void setEndFrame(float val);", "public void setFrameReceiver(IFrameEndReceiver frameEndReceiver) {\n this.frameEndReceiver = frameEndReceiver;\n }", "public int getEndFrame() {\n return endFrame;\n }", "public void en...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Save spans of given type into the file, one per line. Linefeeds in strings are replaced with spaces.
public void saveTypesAsStrings(TextLabels labels,File file,boolean includeOffset) throws IOException { PrintStream out = new PrintStream(new FileOutputStream(file)); for (Iterator j=labels.getTypes().iterator(); j.hasNext(); ) { String type = (String)j.next(); for (Span.Looper i=labels.instanceIterator(type)...
[ "@Override\n public void add(Type type) {\n try (BufferedWriter bufferedWriter = new BufferedWriter(new FileWriter(file, true))) {\n bufferedWriter.write(type.getId() + \" \" + type.getName() );\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n }", "privat...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Insert new data into the provider with the given ContentValues.
@Override public Uri insert(Uri uri, ContentValues contentValues) { final int match = sUriMatcher.match(uri); switch (match) { case DATA: return insertData(uri, contentValues); default: throw new IllegalArgumentException("Insertion is not suppo...
[ "@Override\n public Uri insert(Uri uri, ContentValues contentValues) {\n final int match = sUriMatcher.match(uri);\n switch (match) {\n case DATA:\n return insertValue(uri, contentValues, DataEntry.COLUMN_NAME, DataEntry.TABLE_NAME);\n default:\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
void register(OnBookListener listener, String str);
void unregister(OnBookListener listener);
[ "public static void register(Object listener) {\n bus.register(listener);\n }", "public void registerListeners();", "public abstract void addListener(EventListener eventListener, String componentName);", "public void registerListener(TodoListener listener);", "void addListener( AvailabilityListene...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
adding the value and put in vertices.
@Override public void add(T value) { Vertex<T> vertex = new Vertex<>(value); vertices.put(value, vertex); }
[ "@Override\n public void addValue(T value) {\n Vertex<T> vertex = new Vertex<>(value);\n vertices.put(value,vertex);\n }", "public void addVertex(int value) {\n if (hasVertex(value)) {\n throw new IllegalArgumentException(value + \" is already in the graph\");\n }\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns all Tiles in viewRadius range. The Pythagorean theorem is used. This Method dosn't uses breadthfirst search.
public Set<Tile> getTilesInRadius(Tile tile, int radius) { Set<Tile> tiles = new HashSet<Tile>(); for (Tile locOffset : getTilesOffsetRadius(radius)) { Tile newLoc = getTile(tile, locOffset); tiles.add(newLoc); } return tiles; }
[ "public Set<Tile> getTilesInAttackRadius(Tile tile, int radius) {\n\n\t\tSet<Tile> vOffsets = new HashSet<Tile>();\n\t\tint mx = radius;\n\t\tfor (int row = -mx; row <= mx; ++row) {\n\t\t\tfor (int col = -mx; col <= mx; ++col) {\n\t\t\t\tint d = row * row + col * col;\n\t\t\t\tif (d <= radius * radius + 1) {\n\t\t\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
DATABASE MAPPING : active_status ( VARCHAR )
public void setActiveStatus( String activeStatus ) { this.activeStatus = activeStatus; }
[ "DBStatus getStatus() ;", "public void setActiveStatus(int value) {\n this.activeStatus = value;\n }", "public int getActiveStatus() {\n return activeStatus;\n }", "public void setActive()\n\t{\n\t\tif(status != ConnectionStatus.DISCONNECTED)\n\t\t\tstatus = ConnectionStatus.ACTIVE;\n\t}",...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Remove comments to have more jframe boxes or to put in loops. /JFrame window = new JFrame("Hello World"); window.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); window.setSize(600, 600); window.setVisible(true); JFrame frame = new JFrame("Hello Seccond Frame"); frame.setVisible(true); frame.setSize(500, 500); frame.set...
public static void main(String[] args) { SwingUtilities.invokeLater(new Runnable(){ public void run() { JFrame frame2 = new JFrame("Hello Third Frame"); frame2.setVisible(true); frame2.setSize(400, 300); frame2.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); } }); ...
[ "private void makeFrame(){\n frame = new JFrame(\"Rebellion\");\n\n frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);\n frame.setSize(800,800);\n\n makeContent(frame);\n\n frame.setBackground(Color.getHSBColor(10,99,35));\n frame.pack();\n frame.setVisib...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the current ButlerWeights object.
public ButlerWeights getWeights() { return currentWeights; }
[ "ButlerWeights getWeights();", "public double getWeighting() {\r\n return weighting;\r\n }", "public Matrix getWeight() {\n return weights;\n }", "public double[] getRGBWeights() {\n\t\treturn weights;\n\t}", "public double getWeight() {\n\t\tif(weightConfiguration == null) {\n\t\t\tretu...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the allow External Senders.
public Boolean getAllowExternalSenders() { return this.allowExternalSenders; }
[ "public void setAllowExternalSenders(Boolean value) { \r\n this.allowExternalSenders = value; \r\n valueChanged(\"allowExternalSenders\", value);\r\n\r\n }", "public java.util.List<DirectoryObject> getAcceptedSenders() {\r\n return this.acceptedSenders; \r\n }", "@ZAttr(id=1138)\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Removes the entity referred to by entityID from the cache and notifies peer caches.
public void remove(EntityIdentifier entityID) throws CachingException { this.remove(entityID.getType(), entityID.getKey()); }
[ "public void removeById(final ID entityId);", "void evictFromCache( Long id );", "public void remove(IBasicEntity ent) throws CachingException {\n this.remove(ent.getEntityIdentifier());\n }", "@Override\n public void remove(I entityId)\n {\n // Get the existing entity object and remove...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Setter method for property body.
public void setBody(Object body) { this.body = body; }
[ "public void setBody(String body) {\n this.body = body;\n\n }", "public void setBody(String _body) {\n this._body = _body;\n }", "public void setBody(String body)\n\t{\n\t\tm_sBody=body;\t\n\t}", "void setBody (DBody body);", "public void setBody (String body) {\n\t\tresetText(body);\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Costruttori Costruttore di default che attribuisce alla persona: "Nome" come nome e "Cognome" come cognome;
public Persona() { nome = "Nome"; cognome = "Cognome"; }
[ "public Contribuinte()\n {\n this.nif = \"\";\n this.nome = \"\";\n this.morada = \"\"; \n }", "public Persona(String NomeP , String CognomeP)\n {\n nome = NomeP;\n cognome = CognomeP;\n }", "public void crearPersona(){\r\n persona = new Persona();\r\n per...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
notifies all command interpreters that they won't receive commands anymore and removes them from the list of command interpreters
public synchronized void removeAllCommandInterpreters() { for (CommandInterpreter commandInterpreter : commandInterpreters) { commandInterpreter.willFinishInterpretingCommands(); } commandInterpreters.clear(); }
[ "public void removeAllCommands();", "public void removeAllCommands()\r\n {\r\n if (isTimelapse()) setTimelapseCommand(Command.getNothingCommand());\r\n for (Channel channel : getChannels()) {\r\n for (Block block : channel.getSetting().getBlocks()) {\r\n block.setCommand...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Obtains the new version of the class
public static Class<?> getNewVersion(Class<?> clazz) { Class<?> ret = versions.get(clazz.getName().hashCode()); if (ret != null) return ret; return clazz; }
[ "public static Class<?> getNewVersion(String className) {\n Class<?> ret = versions.get(className.hashCode());\n if (ret != null)\n return ret;\n return null;\n }", "public String getNewVersion() {\n return newVersion;\n }", "public long getClassVersion() {\n \t\tret...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Method to revert the temporary parameters for this run.
public void revertTemporaryParameters() { if (this.getString(ParamString.DB_TABLE_TRIPS).endsWith("_" + this.getString(ParamString.RUN_IDENTIFIER))) this.setString(ParamString.DB_TABLE_TRIPS, this.getString(ParamString.DB_TABLE_TRIPS) .repl...
[ "public void revert() {\r\n\r\n\t}", "final public void temporarilyReset()\n\t{\n\t\tthis.m_savedOutputMode = this.OUTPUT_MODE;\n\t\tthis.m_savedVariables.clear();\n\t\tfor (int i = 0; i < this.m_variables.size(); i++)\n\t\t{\n\t\t\tthis.m_savedVariables.add(this.m_variables.get(i));\n\t\t}\n\t\tresetVariables();...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
int result = FOOTER; if (position < items.size()) result = (items.get(position).category == null) ? ITEM : CATEGORY; return result;
@Override public int getItemViewType(int position) { return (items.get(position).category == null) ? ITEM : CATEGORY; }
[ "@Override\n public int getItemViewType(int position) {\n if (position == initMyCount) {\n return 3;\n } else {\n return 0;\n }\n }", "public abstract CharSequence getFooter();", "@Override\n public int getItemViewType(int position) {\n if(position < al...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the diagnosticsUpload property: Configuration for uploading packet core diagnostics.
public DiagnosticsUploadConfiguration diagnosticsUpload() { return this.diagnosticsUpload; }
[ "public UploadDiagnostics getUploadDiagnostics() {\n\t\treturn uploadDiagnostics;\n\t}", "public PacketCoreControlPlanePropertiesFormat withDiagnosticsUpload(\n DiagnosticsUploadConfiguration diagnosticsUpload) {\n this.diagnosticsUpload = diagnosticsUpload;\n return this;\n }", "public ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method calculates the intersecting sides in a very performant way. It returns a List of int values, which gives the sides of the box, on which the intersection happened. The following values are the possible results: 1 The front side intersects. 2 The back side intersects. 3 The top side intersects. 4 The bottom s...
public List<Integer> getIntersectingSides(BoundingBox box) { List<Integer> results = new ArrayList<>(6); if (center.x + xExtent >= box.center.x - box.xExtent) { results.add(1); } if (center.x - xExtent <= box.center.x + box.xExtent) { results.add(2); } if (center.z + zExtent >= box.center.z - box.zExt...
[ "@Override\n public List<Map.Entry<RealVector, RealVector>> getBoundaryVectors() {\n\n // Build relative vectors between vertices\n RealVector relVectorBackFront = new ArrayRealVector(new double[] {0.0, getLength(), 0.0});\n RealVector relVectorLeftRight = new ArrayRealVector(new double[] {g...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Records all autotuning results per algorithm. repeated .tensorflow.AutotuneResult results = 2;
public java.util.List<tensorflow.Autotuning.AutotuneResult> getResultsList() { return results_; }
[ "tensorflow.Autotuning.AutotuneResult getResults(int index);", "java.util.List<tensorflow.Autotuning.AutotuneResult> \n getResultsList();", "tensorflow.Autotuning.AutotuneResult.FailureResult getFailure();", "tensorflow.Autotuning.AutotuneResultOrBuilder getResultsOrBuilder(\n int index);", "t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Determine if client detection is possible on the given platform
public static boolean isClientDetectablePlatform(ClientInfo sClientInfo) { boolean result = false; if (sClientInfo != null) { result = sClientInfo.osVista() || sClientInfo.osWin32() || sClientInfo.osWin64() || isMacClientDetectablePlatform(sClientInfo); ...
[ "boolean isPlatform();", "boolean matchPlatform(Platform platform);", "public static boolean isMacClientDetectablePlatform(ClientInfo sClientInfo) {\r\n // Once the mac client is available with the browser plugin we can enable this.\r\n // sClientInfo.osMacOSX() & (sClientInfo.isSafari() || sClien...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "entryRuleXNumberLiteral" $ANTLR start "ruleXNumberLiteral" ../br.ufpe.cin.Tupi/srcgen/br/ufpe/cin/parser/antlr/internal/InternalTupi.g:6248:1: ruleXNumberLiteral returns [EObject current=null] : ( () ( (lv_value_1_0= ruleNumber ) ) ) ;
public final EObject ruleXNumberLiteral() throws RecognitionException { EObject current = null; AntlrDatatypeRuleToken lv_value_1_0 = null; enterRule(); try { // ../br.ufpe.cin.Tupi/src-gen/br/ufpe/cin/parser/antlr/internal/InternalTupi.g:6251:28: ( ( () ( (...
[ "public final EObject ruleXNumberLiteral() throws RecognitionException {\n EObject current = null;\n\n AntlrDatatypeRuleToken lv_value_1_0 = null;\n\n\n enterRule(); \n \n try {\n // ../org.xtext.scripting/src-gen/org/xtext/scripting/parser/antlr/internal/InternalS...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns true if field isinctransfer is set (has been assigned a value) and false otherwise
public boolean isSetIsinctransfer() { return __isset_bit_vector.get(__ISINCTRANSFER_ISSET_ID); }
[ "public boolean isSetF() {\n return this.f != null;\n }", "public boolean isSetFax() {\n return this.fax != null;\n }", "public boolean infectionPresent() {\r\n\t boolean infectionPresent = false;\r\n\t \r\n\t /* Sets infectionPresent to true if any button is checked, and fals...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the pixels of one color channel from a FloatProcessor.
public void setPixels(int channelNumber, FloatProcessor fp) { float[] fPixels = (float[]) fp.getPixels(); float value; int size = width * height; int shift = 16 - 8 * channelNumber; int resetMask = 0xffffffff ^ (255 << shift); for (int i = 0; i < size; i++) { value = fPixels[i] + 0.5f; if (value < 0f)...
[ "public void setBrightness(FloatProcessor fp) {\n\t\tint c, r, g, b;\n\t\tint size = width * height;\n\t\tfloat[] hsb = new float[3];\n\t\tfloat[] brightness = (float[]) fp.getPixels();\n\t\tif (brightness.length != size)\n\t\t\tthrow new IllegalArgumentException(\"fp is wrong size\");\n\t\tfor (int i = 0; i < size...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This function will change the value of any additional components that have been added to the game, e.g. updating lives remaining on JTextArea.
public void updateComponents(){ }
[ "private void updateUi() {\n gameController.setLifeCount(life.getRemaining(), life.getTotal());\n gameController.setScoreCount(score.getValue());\n }", "void updateControls();", "public void updateUI() {\n age.setText(ageSharedPref);\n height.setText(heightSharedPref);\n weight.setTe...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Invert state of shift key
private void invertS() { isShiftDown = !isShiftDown; terminal.setIsShiftDown(isShiftDown); }
[ "TriStateBoolean isShiftKeyDown();", "void invertAllBits();", "private void _setUnshifted ()\r\n {\r\n m_bBase64mode = false;\r\n m_nBitsRead = 0;\r\n m_nTempChar = 0;\r\n }", "private void invertC() {\r\n isCtrlDown = !isCtrlDown;\r\n terminal.setIsCtrlDown(isCtrlDown);\r\n }", ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Set the parse error column number
public void setParseErrorColNumber(int colNumber) { this.parseErrorColNumber = colNumber; }
[ "public int getParseErrorColNumber() {\n return this.parseErrorColNumber;\n }", "public void setParseErrorLineNumber(int lineNumber) {\n this.parseErrorLineNumber = lineNumber;\n }", "public void setParseErrorIndex(int index) {\n this.parseErrorIndex = index;\n }", "public void s...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
ADMIN ENDPOINTS Adds a new shipyard.
@Secured({"ROLE_ADMIN"}) @PostMapping("/admin/add") public ResponseEntity<ShipyardDTO> addShipyard(@Valid @RequestBody final ShipyardCommand shipyardCommand) { return ResponseEntity.status(HttpStatus.OK) .body(shipyardService.addShipyard(shipyardCommand)); }
[ "Flight addStewardToFlight(Flight flight, Steward steward);", "public void addCard()\n\t{\n\t\tsylladexcards.add(new SylladexCard(id, this));\n\t\trefreshDock();\n\t\tid++;\n\t}", "void addSeat();", "@RequestMapping(method = RequestMethod.POST, consumes = MediaType.APPLICATION_JSON_VALUE)\n public void inser...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the name and short name properties on the given Periods which don't have the name property already set.
private void setNames( List<Period> periods ) { for ( Period period : periods ) { if ( period.getName() == null ) // Crosstabulated relative periods { // ------------------------------------------------------------- // Static periods + index re...
[ "public void setPeriodName(String value) {\n setAttributeInternal(PERIODNAME, value);\n }", "public void setPeriod(EPPNameWatchPeriod newPeriod) {\n\t\tperiod = newPeriod;\n\t}", "public void setName(String first, String last)\n {\n firstName = first;\n lastName = last;\n }", "pr...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Create an aliased hrdb.hr_cms_media table reference
public HrCmsMedia(String alias) { this(alias, HR_CMS_MEDIA); }
[ "public String getSharedMediaTableCreateQuery()\n\t{\n\t\tString sql = \"CREATE TABLE IF NOT EXISTS \" + DBConstants.SHARED_MEDIA_TABLE + \" (\" + DBConstants.MESSAGE_ID + \" INTEGER PRIMARY KEY, \"\n\t\t\t\t+ DBConstants.MSISDN + \" TEXT, \" + DBConstants.GROUP_PARTICIPANT + \" TEXT, \" + DBConstants.TIMESTAMP + \...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns true if field title is set (has been assigned a value) and false otherwise
public boolean isSetTitle() { return this.title != null; }
[ "public boolean isSetTitle() {\n return this.title != null;\n }", "public boolean isSetTitle() {\n return this.Title != null;\n }", "public boolean isSetExamTitle() {\n return this.examTitle != null;\n }", "public boolean isSetOriginal_title() {\n return this.original_title != null;\n }", "p...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Walks through the query tokens, intersecting the sets of documents having those tokens. At the end, the documents whose tokens are totally covered by the query are considered to be the best matches
public Set<Integer> bestMatches(String query) { Iterable<String> tokens = tokenizer.tokenize(query); StringBuilder buf = new StringBuilder(); buf.append(' '); Map<Integer,Integer> docToFreq = new HashMap<Integer,Integer>(); for (String token: tokens) { buf.append(t...
[ "private Map<Integer, Double> runNear(Node root, List<Map<Integer, Double>> matches) {\n\t\tList<Map<Integer, InvertedListEntry>> allLists = new ArrayList<Map<Integer, InvertedListEntry>>();\n\t\tint maxDist = ((NearOperator) root.getOperator()).getDistance();\n\t\t\n\t\tfor(Node child : root.getChildren()) {\n\t\t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }