📄 photo.java
字号:
package no.auc.one.portableplayer.lms;
import java.io.*;
public class Photo extends ImageItem {
// Optional
private String album = DidlObject.SERIALIZED_NULL_STRING_PROPERTY;
private final static String CLASSTYPE = "object.item.imageItem.photo";
public String classType() {
return CLASSTYPE;
}
public Photo(
int id,
int parentId,
String title,
boolean restricted,
String localUrl)
{
super(id, parentId, title, restricted, localUrl);
}
public Photo(DataInput di) throws IOException {
super(di);
album = di.readUTF();
}
public void serialize(DataOutput dout) throws IOException {
super.serialize(dout);
dout.writeUTF(album);
}
public void serializeXml(PrintStream ps) {
super.serializeXml(ps);
if(!album.equals(DidlObject.SERIALIZED_NULL_STRING_PROPERTY)) {
ps.print("<upnp:album>");
ps.print(album);
ps.print("</upnp:album>");
}
}
public String getAlbum() {
return album;
}
public void setAlbum(String album) {
this.album = album;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -