public void addAttribute(String name, String value) { Attribute attr = new Attribute(name, value); addAttribute(attr); }
public void setAttribute(String name, String value) { Attribute attr = getAttribute(name); if (attr != null) { attr.setValue(value); return; } attr = new Attribute(name, value); addAttribute(attr); }
public boolean set(Node otherNode) { if (otherNode == null) return false; setName(otherNode.getName()); setValue(otherNode.getValue()); removeAllAttributes(); int nOtherAttributes = otherNode.getNAttributes(); for (int n=0; n<nOtherAttributes; n++) { Attribute otherAttr = otherNode.getAttribute(n); Attribute thisAttr = new Attribute(otherAttr); addAttribute(thisAttr); } removeAllNodes(); int nOtherChildNodes = otherNode.getNNodes(); for (int n=0; n<nOtherChildNodes; n++) { Node otherChildNode = otherNode.getNode(n); Node thisChildNode = new Node(); thisChildNode.set(otherChildNode); addNode(thisChildNode); } return true; }
public void addAttribute(String name, String value) { Attribute attr = new Attribute(name, value); addAttribute(attr); }
public void addAttribute(String name, String value) { Attribute attr = new Attribute(name, value); addAttribute(attr); }
public void addAttribute(String name, String value) { Attribute attr = new Attribute(name, value); addAttribute(attr); }
public void addAttribute(String name, String value) { Attribute attr = new Attribute(name, value); addAttribute(attr); }
public AttributeList getAttributeList() { AttributeList attrList = new AttributeList(); // Size long fsize = mp3File.length(); Attribute sizeStr = new Attribute(ItemNode.SIZE, Long.toString(fsize)); attrList.add(sizeStr); return attrList; }
public AttributeList getAttributeList() { AttributeList attrList = new AttributeList(); // Size long fsize = mp3File.length(); Attribute sizeStr = new Attribute(ItemNode.SIZE, Long.toString(fsize)); attrList.add(sizeStr); return attrList; }
public AttributeList getAttributeList() { AttributeList attrList = new AttributeList(); try { // Size long fsize = mpegFile.length(); Attribute sizeStr = new Attribute(ItemNode.SIZE, Long.toString(fsize)); attrList.add(sizeStr); } catch (Exception e) { Debug.warning(e); } return attrList; }
public AttributeList getAttributeList() { AttributeList attrList = new AttributeList(); try { // Size long fsize = mpegFile.length(); Attribute sizeStr = new Attribute(ItemNode.SIZE, Long.toString(fsize)); attrList.add(sizeStr); } catch (Exception e) { Debug.warning(e); } return attrList; }
public void setAttribute(String name, String value) { Attribute attr = getAttribute(name); if (attr != null) { attr.setValue(value); return; } attr = new Attribute(name, value); addAttribute(attr); }
public void setAttribute(String name, String value) { Attribute attr = getAttribute(name); if (attr != null) { attr.setValue(value); return; } attr = new Attribute(name, value); addAttribute(attr); }
public void setAttribute(String name, String value) { Attribute attr = getAttribute(name); if (attr != null) { attr.setValue(value); return; } attr = new Attribute(name, value); addAttribute(attr); }
public void setAttribute(String name, String value) { Attribute attr = getAttribute(name); if (attr != null) { attr.setValue(value); return; } attr = new Attribute(name, value); addAttribute(attr); }
public void setRecordedInfo(MythRecordedInfo info) { recInfo = info; if (info == null) return; // Title setTitle(info.getTitle()); // Creator setCreator(""); // Media Class setUPnPClass(UPnP.OBJECT_ITEM_VIDEOITEM_MOVIE); // Date setDate(info.getStartTime()); setStorageUsed(info.getFileSize()); // ProtocolInfo String protocol = ConnectionManager.HTTP_GET + ":*:" + MIME_TYPE + ":*"; String id = getID(); String url = getContentDirectory().getContentExportURL(id); AttributeList attrList = new AttributeList(); Attribute attr = new Attribute(ItemNode.SIZE, Long.toString(info.getFileSize())); attrList.add(attr); setResource(url, protocol, attrList); }
public void setRecordedInfo(MythRecordedInfo info) { recInfo = info; if (info == null) return; // Title setTitle(info.getTitle()); // Creator setCreator(""); // Media Class setUPnPClass(UPnP.OBJECT_ITEM_VIDEOITEM_MOVIE); // Date setDate(info.getStartTime()); setStorageUsed(info.getFileSize()); // ProtocolInfo String protocol = ConnectionManager.HTTP_GET + ":*:" + MIME_TYPE + ":*"; String id = getID(); String url = getContentDirectory().getContentExportURL(id); AttributeList attrList = new AttributeList(); Attribute attr = new Attribute(ItemNode.SIZE, Long.toString(info.getFileSize())); attrList.add(attr); setResource(url, protocol, attrList); }
public boolean set(Node otherNode) { if (otherNode == null) return false; setName(otherNode.getName()); setValue(otherNode.getValue()); removeAllAttributes(); int nOtherAttributes = otherNode.getNAttributes(); for (int n=0; n<nOtherAttributes; n++) { Attribute otherAttr = otherNode.getAttribute(n); Attribute thisAttr = new Attribute(otherAttr); addAttribute(thisAttr); } removeAllNodes(); int nOtherChildNodes = otherNode.getNNodes(); for (int n=0; n<nOtherChildNodes; n++) { Node otherChildNode = otherNode.getNode(n); Node thisChildNode = new Node(); thisChildNode.set(otherChildNode); addNode(thisChildNode); } return true; }
public boolean set(Node otherNode) { if (otherNode == null) return false; setName(otherNode.getName()); setValue(otherNode.getValue()); removeAllAttributes(); int nOtherAttributes = otherNode.getNAttributes(); for (int n=0; n<nOtherAttributes; n++) { Attribute otherAttr = otherNode.getAttribute(n); Attribute thisAttr = new Attribute(otherAttr); addAttribute(thisAttr); } removeAllNodes(); int nOtherChildNodes = otherNode.getNNodes(); for (int n=0; n<nOtherChildNodes; n++) { Node otherChildNode = otherNode.getNode(n); Node thisChildNode = new Node(); thisChildNode.set(otherChildNode); addNode(thisChildNode); } return true; }