| 1 5 6 package com.raptus.owxv3.api; 7 8 import com.raptus.owxv3.Constants; 9 10 38 public class GResFileLink extends Object  39 { 40 43 protected GResFile gresfile = null; 44 45 46 49 protected String srctable = null; 50 51 54 protected String ownerVModule = null; 55 56 57 60 protected int linkid = 0; 61 62 65 public int getRowID() { return gresfile.getRowID(); } 66 67 68 71 public int getUsageCount() { return gresfile.getUsageCount(); } 72 73 74 77 public long getFileSize() { return gresfile.getFileSize(); } 78 79 80 83 public String getFileURL() { return gresfile.getFileURL(); } 84 85 88 public String getCategory() { return gresfile.getCategory(); } 89 90 91 94 public String getType() { return gresfile.getType(); } 95 96 97 100 public String getInfo() { return gresfile.getInfo(); } 101 102 103 106 public String getFileName(){ 107 String fileURL=getFileURL(); 108 if(fileURL.lastIndexOf(Constants.URL_SEPARATOR)==-1) return fileURL; 109 return fileURL.substring( fileURL.lastIndexOf(Constants.URL_SEPARATOR)+1 ); 110 } 111 112 113 116 public boolean isPicture(){ 117 return (gresfile instanceof com.raptus.owxv3.api.GResPicture); 118 } 119 120 123 public int getPictureWidth(){ 124 if(! isPicture() ) return 0; 125 return ((com.raptus.owxv3.api.GResPicture)gresfile).getPictureWidth(); 126 } 127 128 131 public int getPictureHeight(){ 132 if(! isPicture() ) return 0; 133 return ((com.raptus.owxv3.api.GResPicture)gresfile).getPictureHeight(); 134 } 135 136 137 140 public String getSrctable() { return srctable; } 141 142 145 public void setSrctable(String s) { this.srctable=s; } 146 147 148 151 public String getOwnerVModule() { return ownerVModule; } 152 153 156 public void setOwnerVModule(String s) { this.ownerVModule=s; } 157 158 159 162 public int getLinkid() { return linkid; } 163 164 167 public void setLinkid(int id) { this.linkid=id; } 168 169 172 public GResFile getGResFile() { return gresfile; } 173 174 177 public void setGResFile(GResFile file) { this.gresfile=file; } 178 179 180 181 182 } 183 184 185 186 | Popular Tags |