Merge branch 'develop' of https://github.com/mz-automation/openiec61850 into mz-automation-develop

pull/11/head
Stefan Feuerhahn 7 years ago
commit 646f7f4907

@ -10,6 +10,7 @@ import java.io.OutputStream;
import java.io.Serializable; import java.io.Serializable;
import org.openmuc.jasn1.ber.*; import org.openmuc.jasn1.ber.*;
import org.openmuc.jasn1.ber.types.*; import org.openmuc.jasn1.ber.types.*;
import org.openmuc.jasn1.ber.types.string.BerVisibleString;
public class AlternateAccessSelection implements Serializable { public class AlternateAccessSelection implements Serializable {

@ -9,6 +9,7 @@ import java.io.InputStream;
import java.io.OutputStream; import java.io.OutputStream;
import java.io.Serializable; import java.io.Serializable;
import org.openmuc.jasn1.ber.*; import org.openmuc.jasn1.ber.*;
import org.openmuc.jasn1.ber.types.*;
public class ConfirmedRequestPDU implements Serializable { public class ConfirmedRequestPDU implements Serializable {

@ -9,6 +9,7 @@ import java.io.InputStream;
import java.io.OutputStream; import java.io.OutputStream;
import java.io.Serializable; import java.io.Serializable;
import org.openmuc.jasn1.ber.*; import org.openmuc.jasn1.ber.*;
import org.openmuc.jasn1.ber.types.BerInteger;
public class ConfirmedResponsePDU implements Serializable { public class ConfirmedResponsePDU implements Serializable {

@ -13,6 +13,7 @@ import java.util.Iterator;
import java.io.Serializable; import java.io.Serializable;
import org.openmuc.jasn1.ber.*; import org.openmuc.jasn1.ber.*;
import org.openmuc.jasn1.ber.types.*; import org.openmuc.jasn1.ber.types.*;
import org.openmuc.jasn1.ber.types.string.BerVisibleString;
public class DeleteNamedVariableListRequest implements Serializable { public class DeleteNamedVariableListRequest implements Serializable {

@ -9,6 +9,7 @@ import java.io.InputStream;
import java.io.OutputStream; import java.io.OutputStream;
import java.io.Serializable; import java.io.Serializable;
import org.openmuc.jasn1.ber.*; import org.openmuc.jasn1.ber.*;
import org.openmuc.jasn1.ber.types.string.BerVisibleString;
public class ObjectName implements Serializable { public class ObjectName implements Serializable {

@ -57,8 +57,8 @@ public final class BdaEntryTime extends BasicDataAttribute {
if (value.length != 6) { if (value.length != 6) {
return -1; return -1;
} }
return ((value[0] & 0xffl) << 24) + ((value[1] & 0xffl) << 16) + ((value[2] & 0xffl) << 8) + (value[3] & 0xffl) return (((value[0] & 0xffl) << 24) + ((value[1] & 0xffl) << 16) + ((value[2] & 0xffl) << 8) + (value[3] & 0xffl)
+ (((value[4] & 0xffl) << 8) + (value[5] & 0xffl)) * 86400000l; + (((value[4] & 0xffl) << 8) + (value[5] & 0xffl)) * 86400000l) + 441763200000l;
} }
public void setValue(byte[] value) { public void setValue(byte[] value) {

@ -944,10 +944,13 @@ public final class ClientAssociation {
long fileSize = entry.getFileAttributes().getSizeOfFile().longValue(); long fileSize = entry.getFileAttributes().getSizeOfFile().longValue();
Calendar lastModified; Calendar lastModified = null;
try { try {
lastModified = entry.getFileAttributes().getLastModified().asCalendar();
if (entry.getFileAttributes().getLastModified() != null)
lastModified = entry.getFileAttributes().getLastModified().asCalendar();
} catch (ParseException e) { } catch (ParseException e) {
throw new ServiceError(ServiceError.FAILED_DUE_TO_COMMUNICATIONS_CONSTRAINT, throw new ServiceError(ServiceError.FAILED_DUE_TO_COMMUNICATIONS_CONSTRAINT,

@ -21,6 +21,11 @@ public class FileInformation {
return fileSize; return fileSize;
} }
/**
* Get the time stamp of last modification. As it is an optional attribute the return value can be null
*
* @return the time stamp of last modification, or null if the time stamp is not present
*/
public Calendar getLastModified() { public Calendar getLastModified() {
return lastModified; return lastModified;
} }

Loading…
Cancel
Save