Java Code Examples for org.w3c.dom.Node.getTextContent()

The following are Jave code examples for showing how to use getTextContent() of the org.w3c.dom.Node class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
+ Save this method
Example 1
Project: kaltura-ce-sakai-extension   File: KalturaRule.java   View Source Code Vote up 10 votes
public KalturaRule(Element node) throws KalturaApiException {
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("message")) {
            this.message = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("actions")) {
            this.actions = ParseUtils.parseArray(KalturaAccessControlAction.class, aNode);
            continue;
        } else if (nodeName.equals("conditions")) {
            this.conditions = ParseUtils.parseArray(KalturaCondition.class, aNode);
            continue;
        } else if (nodeName.equals("contexts")) {
            this.contexts = ParseUtils.parseArray(KalturaAccessControlContextTypeHolder.class, aNode);
            continue;
        } else if (nodeName.equals("stopProcessing")) {
            this.stopProcessing = ParseUtils.parseBool(txt);
            continue;
        } 
    }
}
 
Example 2
Project: kaltura-ce-sakai-extension   File: KalturaExtendingItemMrssParameter.java   View Source Code Vote up 7 votes
public KalturaExtendingItemMrssParameter(Element node) throws KalturaApiException {
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("xpath")) {
            this.xpath = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("identifier")) {
            this.identifier = ParseUtils.parseObject(KalturaObjectIdentifier.class, aNode);
            continue;
        } else if (nodeName.equals("extensionMode")) {
            this.extensionMode = KalturaMrssExtensionMode.get(ParseUtils.parseInt(txt));
            continue;
        } 
    }
}
 
Example 3
Project: kaltura-ce-sakai-extension   File: KalturaAssetParamsResourceContainer.java   View Source Code Vote up 6 votes
public KalturaAssetParamsResourceContainer(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("resource")) {
            this.resource = ParseUtils.parseObject(KalturaContentResource.class, aNode);
            continue;
        } else if (nodeName.equals("assetParamsId")) {
            this.assetParamsId = ParseUtils.parseInt(txt);
            continue;
        } 
    }
}
 
Example 4
Project: kaltura-ce-sakai-extension   File: KalturaSearch.java   View Source Code Vote up 6 votes
public KalturaSearch(Element node) throws KalturaApiException {
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("keyWords")) {
            this.keyWords = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("searchSource")) {
            this.searchSource = KalturaSearchProviderType.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("mediaType")) {
            this.mediaType = KalturaMediaType.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("extraData")) {
            this.extraData = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("authData")) {
            this.authData = ParseUtils.parseString(txt);
            continue;
        } 
    }
}
 
Example 5
Project: kaltura-ce-sakai-extension   File: KalturaSystemPartnerOveragedLimit.java   View Source Code Vote up 6 votes
public KalturaSystemPartnerOveragedLimit(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("overagePrice")) {
            this.overagePrice = ParseUtils.parseFloat(txt);
            continue;
        } else if (nodeName.equals("overageUnit")) {
            this.overageUnit = ParseUtils.parseFloat(txt);
            continue;
        } 
    }
}
 
Example 6
Project: kaltura-ce-sakai-extension   File: KalturaImageFlavorParamsOutput.java   View Source Code Vote up 6 votes
public KalturaImageFlavorParamsOutput(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("densityWidth")) {
            this.densityWidth = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("densityHeight")) {
            this.densityHeight = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("sizeWidth")) {
            this.sizeWidth = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("sizeHeight")) {
            this.sizeHeight = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("depth")) {
            this.depth = ParseUtils.parseInt(txt);
            continue;
        } 
    }
}
 
Example 7
Project: Tarski   File: mxObjectCodec.java   View Source Code Vote up 6 votes
/**
 * Reads the specified child into the given object.
 */
protected void decodeChild(mxCodec dec, Node child, Object obj) {
  String fieldname = getFieldName(((Element) child).getAttribute("as"));

  if (fieldname == null || !isExcluded(obj, fieldname, child, false)) {
    Object template = getFieldTemplate(obj, fieldname, child);
    Object value = null;

    if (child.getNodeName().equals("add")) {
      value = ((Element) child).getAttribute("value");

      if (value == null) {
        value = child.getTextContent();
      }
    } else {
      value = dec.decode(child, template);
      // System.out.println("Decoded " + child.getNodeName() + "."
      // + fieldname + "=" + value);
    }

    addObjectValue(obj, fieldname, value, template);
  }
}
 
Example 8
Project: kaltura-ce-sakai-extension   File: KalturaBaseEntryFilter.java   View Source Code Vote up 6 votes
public KalturaBaseEntryFilter(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("freeText")) {
            this.freeText = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("isRoot")) {
            this.isRoot = KalturaNullableBoolean.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("categoriesFullNameIn")) {
            this.categoriesFullNameIn = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("categoryAncestorIdIn")) {
            this.categoryAncestorIdIn = ParseUtils.parseString(txt);
            continue;
        } 
    }
}
 
Example 9
Project: kaltura-ce-sakai-extension   File: KalturaCaptionParams.java   View Source Code Vote up 6 votes
public KalturaCaptionParams(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("language")) {
            this.language = KalturaLanguage.get(ParseUtils.parseString(txt));
            continue;
        } else if (nodeName.equals("isDefault")) {
            this.isDefault = KalturaNullableBoolean.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("label")) {
            this.label = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("format")) {
            this.format = KalturaCaptionType.get(ParseUtils.parseString(txt));
            continue;
        } else if (nodeName.equals("sourceParamsId")) {
            this.sourceParamsId = ParseUtils.parseInt(txt);
            continue;
        } 
    }
}
 
Example 10
Project: kaltura-ce-sakai-extension   File: KalturaSearchOperator.java   View Source Code Vote up 6 votes
public KalturaSearchOperator(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("type")) {
            this.type = KalturaSearchOperatorType.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("items")) {
            this.items = ParseUtils.parseArray(KalturaSearchItem.class, aNode);
            continue;
        } 
    }
}
 
Example 11
Project: kaltura-ce-sakai-extension   File: KalturaUrlResource.java   View Source Code Vote up 5 votes
public KalturaUrlResource(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("url")) {
            this.url = ParseUtils.parseString(txt);
            continue;
        } 
    }
}
 
Example 12
Project: openjdk-jdk10   File: DocumentExtFunc.java   View Source Code Vote up 5 votes
public static String test(NodeList list) {
    Node node = list.item(0);
    return "["+node.getNodeName() + ":" + node.getTextContent()+"]";
}
 
Example 13
Project: kaltura-ce-sakai-extension   File: KalturaConversionProfileAssetParamsListResponse.java   View Source Code Vote up 5 votes
public KalturaConversionProfileAssetParamsListResponse(Element node) throws KalturaApiException {
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("objects")) {
            this.objects = ParseUtils.parseArray(KalturaConversionProfileAssetParams.class, aNode);
            continue;
        } else if (nodeName.equals("totalCount")) {
            this.totalCount = ParseUtils.parseInt(txt);
            continue;
        } 
    }
}
 
Example 14
Project: ARCLib   File: ValidationService.java   View Source Code Vote up 5 votes
/**
 * Performs all attribute value checks contained in the validation profile. If the validation has failed (some of the attributes
 * specified in the validation profile do not match their specified values or regex) {@link WrongNodeValue} or
 * {@link InvalidNodeValue} is thrown.
 *
 * @param sipPath path to the SIP
 * @param validationProfileDoc document with the validation profile
 * @param validationProfileId id of the validation profile
 * @throws IOException if some of the files addressed from the validation profile is not found
 * @throws XPathExpressionException if there is an error in the XPath expression
 * @throws SAXException if the validationProfileDoc cannot be parsed
 * @throws ParserConfigurationException
 */
private void performNodeValueChecks(String sipPath, Document validationProfileDoc, String validationProfileId)
        throws IOException, ParserConfigurationException, XPathExpressionException, SAXException {
    XPath xPath =  XPathFactory.newInstance().newXPath();

    NodeList nodes = (NodeList) xPath.compile("/profile/rule/nodeCheck")
            .evaluate(validationProfileDoc, XPathConstants.NODESET);
    for (int i = 0; i< nodes.getLength(); i++) {
        Element element = (Element) nodes.item(i);

        String filePath = element.getElementsByTagName("filePath").item(0).getTextContent();
        String absoluteFilePath = sipPath + filePath;

        String expression = element.getElementsByTagName("xPath").item(0).getTextContent();

        String actualValue =  ValidationChecker.findWithXPath(new FileInputStream(absoluteFilePath), expression).item(0).getTextContent();

        Node valueElement = element.getElementsByTagName("value").item(0);
        if (valueElement != null) {
            String expectedValue = valueElement.getTextContent();
            // compare with value
            if (!expectedValue.equals(actualValue)) {
                log.info("Validation of SIP with profile " + validationProfileId + " failed. Expected value of node at path \"" +
                        expression + "\" is " + expectedValue + ". Actual value is " + actualValue + ".");
                throw new WrongNodeValue(expectedValue, actualValue, absoluteFilePath, expression);                }
        } else {
            //compare with regex
            Node regexElement = element.getElementsByTagName("regex").item(0);
            String regex = regexElement.getTextContent();
            Pattern pattern = Pattern.compile(regex);
            Matcher m = pattern.matcher(actualValue);
            if (!m.matches()) {
                log.info("Validation of SIP with profile " + validationProfileId + " failed. Value " + actualValue + " of node at " +
                        "path \"" + expression + "\" does not match regex " + regex + ".");
                throw new InvalidNodeValue(regex, actualValue, absoluteFilePath, expression);                }
        }
    }
}
 
Example 15
Project: kaltura-ce-sakai-extension   File: KalturaAccessControlProfile.java   View Source Code Vote up 5 votes
public KalturaAccessControlProfile(Element node) throws KalturaApiException {
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("id")) {
            this.id = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("partnerId")) {
            this.partnerId = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("name")) {
            this.name = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("systemName")) {
            this.systemName = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("description")) {
            this.description = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("createdAt")) {
            this.createdAt = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("updatedAt")) {
            this.updatedAt = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("isDefault")) {
            this.isDefault = KalturaNullableBoolean.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("rules")) {
            this.rules = ParseUtils.parseArray(KalturaRule.class, aNode);
            continue;
        } 
    }
}
 
Example 16
Project: kaltura-ce-sakai-extension   File: KalturaDistributionProvider.java   View Source Code Vote up 5 votes
public KalturaDistributionProvider(Element node) throws KalturaApiException {
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("type")) {
            this.type = KalturaDistributionProviderType.get(ParseUtils.parseString(txt));
            continue;
        } else if (nodeName.equals("name")) {
            this.name = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("scheduleUpdateEnabled")) {
            this.scheduleUpdateEnabled = ParseUtils.parseBool(txt);
            continue;
        } else if (nodeName.equals("availabilityUpdateEnabled")) {
            this.availabilityUpdateEnabled = ParseUtils.parseBool(txt);
            continue;
        } else if (nodeName.equals("deleteInsteadUpdate")) {
            this.deleteInsteadUpdate = ParseUtils.parseBool(txt);
            continue;
        } else if (nodeName.equals("intervalBeforeSunrise")) {
            this.intervalBeforeSunrise = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("intervalBeforeSunset")) {
            this.intervalBeforeSunset = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("updateRequiredEntryFields")) {
            this.updateRequiredEntryFields = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("updateRequiredMetadataXPaths")) {
            this.updateRequiredMetadataXPaths = ParseUtils.parseString(txt);
            continue;
        } 
    }
}
 
Example 17
Project: kaltura-ce-sakai-extension   File: KalturaCaptureThumbJobData.java   View Source Code Vote up 5 votes
public KalturaCaptureThumbJobData(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("srcFileSyncLocalPath")) {
            this.srcFileSyncLocalPath = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("actualSrcFileSyncLocalPath")) {
            this.actualSrcFileSyncLocalPath = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("srcFileSyncRemoteUrl")) {
            this.srcFileSyncRemoteUrl = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("thumbParamsOutputId")) {
            this.thumbParamsOutputId = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("thumbAssetId")) {
            this.thumbAssetId = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("srcAssetId")) {
            this.srcAssetId = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("srcAssetType")) {
            this.srcAssetType = KalturaAssetType.get(ParseUtils.parseString(txt));
            continue;
        } else if (nodeName.equals("thumbPath")) {
            this.thumbPath = ParseUtils.parseString(txt);
            continue;
        } 
    }
}
 
Example 18
Project: kaltura-ce-sakai-extension   File: KalturaShortLinkBaseFilter.java   View Source Code Vote up 4 votes
public KalturaShortLinkBaseFilter(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("idEqual")) {
            this.idEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("idIn")) {
            this.idIn = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("createdAtGreaterThanOrEqual")) {
            this.createdAtGreaterThanOrEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("createdAtLessThanOrEqual")) {
            this.createdAtLessThanOrEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("updatedAtGreaterThanOrEqual")) {
            this.updatedAtGreaterThanOrEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("updatedAtLessThanOrEqual")) {
            this.updatedAtLessThanOrEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("expiresAtGreaterThanOrEqual")) {
            this.expiresAtGreaterThanOrEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("expiresAtLessThanOrEqual")) {
            this.expiresAtLessThanOrEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("partnerIdEqual")) {
            this.partnerIdEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("partnerIdIn")) {
            this.partnerIdIn = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("userIdEqual")) {
            this.userIdEqual = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("userIdIn")) {
            this.userIdIn = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("systemNameEqual")) {
            this.systemNameEqual = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("systemNameIn")) {
            this.systemNameIn = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("statusEqual")) {
            this.statusEqual = KalturaShortLinkStatus.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("statusIn")) {
            this.statusIn = ParseUtils.parseString(txt);
            continue;
        } 
    }
}
 
Example 19
Project: kaltura-ce-sakai-extension   File: KalturaDropFolder.java   View Source Code Vote up 4 votes
public KalturaDropFolder(Element node) throws KalturaApiException {
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("id")) {
            this.id = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("partnerId")) {
            this.partnerId = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("name")) {
            this.name = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("description")) {
            this.description = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("type")) {
            this.type = KalturaDropFolderType.get(ParseUtils.parseString(txt));
            continue;
        } else if (nodeName.equals("status")) {
            this.status = KalturaDropFolderStatus.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("conversionProfileId")) {
            this.conversionProfileId = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("dc")) {
            this.dc = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("path")) {
            this.path = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("fileSizeCheckInterval")) {
            this.fileSizeCheckInterval = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("fileDeletePolicy")) {
            this.fileDeletePolicy = KalturaDropFolderFileDeletePolicy.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("autoFileDeleteDays")) {
            this.autoFileDeleteDays = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("fileHandlerType")) {
            this.fileHandlerType = KalturaDropFolderFileHandlerType.get(ParseUtils.parseString(txt));
            continue;
        } else if (nodeName.equals("fileNamePatterns")) {
            this.fileNamePatterns = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("fileHandlerConfig")) {
            this.fileHandlerConfig = ParseUtils.parseObject(KalturaDropFolderFileHandlerConfig.class, aNode);
            continue;
        } else if (nodeName.equals("tags")) {
            this.tags = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("errorCode")) {
            this.errorCode = KalturaDropFolderErrorCode.get(ParseUtils.parseString(txt));
            continue;
        } else if (nodeName.equals("errorDescription")) {
            this.errorDescription = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("ignoreFileNamePatterns")) {
            this.ignoreFileNamePatterns = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("createdAt")) {
            this.createdAt = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("updatedAt")) {
            this.updatedAt = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("lastAccessedAt")) {
            this.lastAccessedAt = ParseUtils.parseInt(txt);
            continue;
        } 
    }
}
 
Example 20
Project: kaltura-ce-sakai-extension   File: KalturaControlPanelCommandBaseFilter.java   View Source Code Vote up 4 votes
public KalturaControlPanelCommandBaseFilter(Element node) throws KalturaApiException {
    super(node);
    NodeList childNodes = node.getChildNodes();
    for (int i = 0; i < childNodes.getLength(); i++) {
        Node aNode = childNodes.item(i);
        String nodeName = aNode.getNodeName();
        String txt = aNode.getTextContent();
        if (nodeName.equals("idEqual")) {
            this.idEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("idIn")) {
            this.idIn = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("createdAtGreaterThanOrEqual")) {
            this.createdAtGreaterThanOrEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("createdAtLessThanOrEqual")) {
            this.createdAtLessThanOrEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("createdByIdEqual")) {
            this.createdByIdEqual = ParseUtils.parseInt(txt);
            continue;
        } else if (nodeName.equals("typeEqual")) {
            this.typeEqual = KalturaControlPanelCommandType.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("typeIn")) {
            this.typeIn = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("targetTypeEqual")) {
            this.targetTypeEqual = KalturaControlPanelCommandTargetType.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("targetTypeIn")) {
            this.targetTypeIn = ParseUtils.parseString(txt);
            continue;
        } else if (nodeName.equals("statusEqual")) {
            this.statusEqual = KalturaControlPanelCommandStatus.get(ParseUtils.parseInt(txt));
            continue;
        } else if (nodeName.equals("statusIn")) {
            this.statusIn = ParseUtils.parseString(txt);
            continue;
        } 
    }
}