Examples of asElement()


Examples of org.apache.pig.backend.hadoop.datastorage.HDataStorage.asElement()

                log.warn("Unable to write Resource Statistics for "+location);
                e.printStackTrace();
            }
        }
        if (printHeaders) {
            ElementDescriptor headerFilePath = storage.asElement(location, headerFileName);
            if (!headerFilePath.exists()) {
                OutputStream os = headerFilePath.create();
                try {
                    String[] names = schema.fieldNames();
View Full Code Here

Examples of org.apache.pig.backend.hadoop.datastorage.HDataStorage.asElement()

    }

    public static InputStream openDFSFile(String fileName, Properties properties) throws IOException{
        DataStorage dds = new HDataStorage(properties);
        ElementDescriptor elem = dds.asElement(fileName);
        return openDFSFile(elem);
    }
   
    public static long getSize(String fileName) throws IOException {
      Configuration conf = PigMapReduce.sJobConf;
View Full Code Here

Examples of org.apache.pig.backend.hadoop.datastorage.HDataStorage.asElement()

        return getSize(fileName, ConfigurationUtil.toProperties(conf));
    }
   
    public static long getSize(String fileName, Properties properties) throws IOException {
      DataStorage dds = new HDataStorage(properties);
        ElementDescriptor elem = dds.asElement(fileName);
      
        // recursively get all the files under this path
        ElementDescriptor[] allElems = getFileElementDescriptors(elem);
       
        long size = 0;
View Full Code Here

Examples of org.apache.pig.backend.hadoop.datastorage.HDataStorage.asElement()

    }

    public static InputStream openDFSFile(String fileName, Properties properties) throws IOException{
        DataStorage dds = new HDataStorage(properties);
        ElementDescriptor elem = dds.asElement(fileName);
        return openDFSFile(elem);
    }
   
    public static long getSize(String fileName) throws IOException {
      Configuration conf = PigMapReduce.sJobConf;
View Full Code Here

Examples of org.apache.pig.backend.hadoop.datastorage.HDataStorage.asElement()

        return getSize(fileName, ConfigurationUtil.toProperties(conf));
    }
   
    public static long getSize(String fileName, Properties properties) throws IOException {
      DataStorage dds = new HDataStorage(properties);
        ElementDescriptor elem = dds.asElement(fileName);
      
        // recursively get all the files under this path
        ElementDescriptor[] allElems = getFileElementDescriptors(elem);
       
        long size = 0;
View Full Code Here

Examples of org.apache.pig.backend.hadoop.datastorage.HDataStorage.asElement()

       
    }

    public static InputStream openDFSFile(String fileName, Properties properties) throws IOException{
        DataStorage dds = new HDataStorage(properties);
        ElementDescriptor elem = dds.asElement(fileName);
        return openDFSFile(elem);
    }
   
    private static InputStream openDFSFile(ElementDescriptor elem) throws IOException{
        ElementDescriptor[] elements = null;
View Full Code Here

Examples of org.jivesoftware.openfire.privacy.PrivacyList.asElement()

                list = manager.getPrivacyList(from.getNode(), listName);
            }
            if (list != null) {
                // Add the privacy list to the result
                childElement = result.setChildElement("query", "jabber:iq:privacy");
                childElement.add(list.asElement());
            }
            else {
                // List not found
                result.setError(PacketError.Condition.item_not_found);
            }
View Full Code Here

Examples of org.waveprotocol.wave.client.editor.content.ContentElement.asElement()

    return getListener(node) != null;
  }

  private static EditModeListener getListener(ContentNode node) {
    ContentElement e = node.asElement();
    return e.asElement() != null ? e.getProperty(EDIT_MODE_LISTENER_PROP) : null;
  }

  /**
   * Sets an EditModeChange listener on this node.
   * @param element
View Full Code Here

Examples of org.waveprotocol.wave.client.editor.content.ContentNode.asElement()

    // element or if it is followed by another line element
    ContentElement lineElement = Line.fromParagraph(e).getLineElement();
    CMutableDocument doc = lineElement.getMutableDoc();
    ContentNode next = doc.getNextSibling(lineElement);
    return next == null
        || (next.asElement() != null && LineRendering.isLineElement(next.asElement()));
  }

  @Override
  public boolean handleEnter(ContentElement element, EditorEvent event) {
    ContentPoint contentPoint = event.getCaret();
View Full Code Here

Examples of org.waveprotocol.wave.model.document.raw.impl.Node.asElement()

    assertSame(null, DocHelper.findElementById(doc, x.asElement(), "y"));
    assertSame(y, DocHelper.findElementById(doc, aroundy.asElement(), "y"));
    assertSame(y, DocHelper.findElementById(doc, y.asElement(), "y"));
    assertSame(null, DocHelper.findElementById(doc, z.asElement(), "y"));
    assertSame(yy, DocHelper.findElementById(doc, yy.asElement(), "y"));
  }

  public void testMatchingElement() {
    MutableDocument<Node, Element, Text> doc = getDoc("<x/>hello");
    Node n = doc.getDocumentElement().getFirstChild();
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.