Examples of indexOf()


Examples of javax.security.auth.x500.X500Principal.indexOf()

            } else if (arg0.charAt(0) == '.') {
                // this is case #3 : a sub-domain
                boolResult = arg1.endsWith(arg0.toLowerCase());
            } else {
                // this is case #2 : any mailbox at a specific domain
                String mailDomain = arg1.substring(arg1.indexOf('@') + 1);
                boolResult = arg0.toLowerCase().equals(mailDomain);
            }
           
            break;
        }
View Full Code Here

Examples of javax.swing.DefaultListModel.indexOf()

        }

        final JList jList = _recentSearchesPopup.getList();
        if (jList != null) {
          final DefaultListModel listModel = (DefaultListModel) jList.getModel();
          final int index = listModel.indexOf(text);
          jList.setSelectedIndex(index);
          _recentSearchesPopup.scrollIndexToVisible(index);
        }
      }
View Full Code Here

Examples of javax.swing.JTextField.indexOf()

                  original.setCapas(capas);

                  if (original.getId() == null) {
                    String url = nombre.getText();

                    if (url.indexOf("?") > -1) {
                      if (!url.endsWith("?")) {
                        url += "&";

                      }
                    } else {
View Full Code Here

Examples of javax.xml.namespace.QName.indexOf()

                        localName = nameElmt.getLocalName();
                        prefix = nameElmt.getPrefix();
                    } else if (args.get(2) instanceof String)  {
                        String qName = (String) args.get(2);
                        if (qName.contains(":")) {
                            int index = qName.indexOf(":");
                            prefix = qName.substring(0, index);
                            localName = qName.substring(index + 1);
                        } else {
                            localName = qName;
                        }
View Full Code Here

Examples of js.lang.NativeArray.indexOf()

                assert array.length() == 0;

                array.push("1");
                assert array.length() == 1;

                int index = array.indexOf("1");
                assert index == 0;

                return index;
            }
        });
View Full Code Here

Examples of net.hydromatic.avatica.ByteString.indexOf()

    final ByteString byteString3 = new ByteString(bytes3);

    assertEquals(0, byteString.indexOf(emptyByteString));
    assertEquals(-1, byteString.indexOf(byteString1));
    assertEquals(1, byteString.indexOf(byteString3));
    assertEquals(-1, byteString3.indexOf(byteString));
  }

  @Test public void testEasyLog10() {
    assertEquals(1, SqlFunctions.digitCount(0));
    assertEquals(1, SqlFunctions.digitCount(1));
View Full Code Here

Examples of net.rim.device.api.util.StringMatch.indexOf()

     * @return
     */
    private String fixTag(String content) {
        StringBuffer contentBuffer = new StringBuffer(content);
        StringMatch matcher = new StringMatch("<");
        int matchOffset = matcher.indexOf(contentBuffer, 0);
        while(matchOffset != -1){
            contentBuffer.delete(matchOffset,matchOffset+4);
            contentBuffer.insert(matchOffset,"<");
            matchOffset = matcher.indexOf(contentBuffer, 0);
        }
View Full Code Here

Examples of net.sf.cindy.Buffer.indexOf()

        }
        buffer.flip();

        // Test length 0
        byte[] pattern = new byte[0];
        assertEquals(0, buffer.indexOf(pattern));

        // Test length 1
        pattern = new byte[1];
        for (int i = 0; i < 10; i++) {
            random.nextBytes(pattern);
View Full Code Here

Examples of net.sf.saxon.om.FastStringBuffer.indexOf()

            // Map the digits and decimal point to use the selected characters

            int[] ib = StringValue.expand(sb);
            int ibused = ib.length;
            int point = sb.indexOf('.');
            if (point == -1) {
                point = sb.length();
            } else {
                ib[point] = dfs.decimalSeparator;
View Full Code Here

Examples of net.sourceforge.chaperon.model.symbol.SymbolList.indexOf()

    assertEquals("Test if symbols are equal", a, list.getSymbol(0));
    assertEquals("Test if symbols are equal", a, list.getSymbol(1));
    assertEquals("Test if symbols are equal", B, list.getSymbol(4));
    assertEquals("Test if symbols are equal", C, list.getSymbol(6));

    assertEquals("Test if indices are equal", 0, list.indexOf(a));
    assertEquals("Test if indices are equal", 5, list.indexOf(c));

    SymbolList list2 = new SymbolList();

    list2.addSymbol(a);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.