3939 * A class representing data to be uploaded to core
4040 */
4141public class SdlFile {
42- private String fileName ;
43- private String filePath ;
44- private byte [] fileData ;
45- private FileType fileType ;
46- private boolean persistentFile ;
47- private boolean isStaticIcon ;
42+ private String fileName ;
43+ private String filePath ;
44+ private byte [] fileData ;
45+ private FileType fileType ;
46+ private boolean persistentFile ;
47+ private boolean isStaticIcon ;
48+ // Overwrite property by default is set to true in SdlFile constructors indicating that a file can be overwritten
49+ private boolean overwrite = true ;
4850
4951 /**
5052 * Creates a new instance of SdlFile
@@ -185,4 +187,20 @@ public void setStaticIcon(boolean staticIcon) {
185187 public boolean isStaticIcon () {
186188 return isStaticIcon ;
187189 }
190+
191+ /**
192+ * Gets the overwrite property for an SdlFile by default its set to true
193+ * @return a boolean value that indicates if a file can be overwritten.
194+ */
195+ public boolean isOverwrite () {
196+ return overwrite ;
197+ }
198+
199+ /**
200+ * Sets the overwrite property for an SdlFile by default its set to true
201+ * @param overwrite a boolean value that indicates if a file can be overwritten
202+ */
203+ public void setOverwrite (boolean overwrite ) {
204+ this .overwrite = overwrite ;
205+ }
188206}
0 commit comments