Merge branch 'status-attaching' into dev

Change-Id: I2935b2ea07af115110a71c5f31d1009d2b2adf2a
diff --git a/src/main/java/org/eclipse/mdm/api/base/model/FileLink.java b/src/main/java/org/eclipse/mdm/api/base/model/FileLink.java
index 74333b9..e942d48 100644
--- a/src/main/java/org/eclipse/mdm/api/base/model/FileLink.java
+++ b/src/main/java/org/eclipse/mdm/api/base/model/FileLink.java
@@ -1,16 +1,16 @@
-/********************************************************************************

- * Copyright (c) 2015-2018 Contributors to the Eclipse Foundation

- *

- * See the NOTICE file(s) distributed with this work for additional

- * information regarding copyright ownership.

- *

- * This program and the accompanying materials are made available under the

- * terms of the Eclipse Public License v. 2.0 which is available at

- * http://www.eclipse.org/legal/epl-2.0.

- *

- * SPDX-License-Identifier: EPL-2.0

- *

- ********************************************************************************/

+/********************************************************************************
+ * Copyright (c) 2015-2018 Contributors to the Eclipse Foundation
+ *
+ * See the NOTICE file(s) distributed with this work for additional
+ * information regarding copyright ownership.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v. 2.0 which is available at
+ * http://www.eclipse.org/legal/epl-2.0.
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ ********************************************************************************/
 
 
 package org.eclipse.mdm.api.base.model;
@@ -156,7 +156,9 @@
 			fileNamePath = getLocalPath().getFileName();
 		} else if (isRemote()) {
 			try {
-				fileNamePath = Paths.get(URLDecoder.decode(remotePath, StandardCharsets.UTF_8.name())).getFileName();
+				//on Windows, Paths.get() cannot handle file urls in the form file://REMOTE_HOST/path/filename
+				String fixedPath = remotePath.replaceFirst("file:", "");
+				fileNamePath = Paths.get(URLDecoder.decode(fixedPath, StandardCharsets.UTF_8.name())).getFileName();
 			} catch (UnsupportedEncodingException e) {
 				throw new IllegalStateException("Unable to decode remote path due to: " + e.getMessage(), e);
 			}
diff --git a/src/main/java/org/eclipse/mdm/api/base/model/Measurement.java b/src/main/java/org/eclipse/mdm/api/base/model/Measurement.java
index efbcc07..d4c1917 100644
--- a/src/main/java/org/eclipse/mdm/api/base/model/Measurement.java
+++ b/src/main/java/org/eclipse/mdm/api/base/model/Measurement.java
@@ -1,16 +1,16 @@
-/********************************************************************************

- * Copyright (c) 2015-2018 Contributors to the Eclipse Foundation

- *

- * See the NOTICE file(s) distributed with this work for additional

- * information regarding copyright ownership.

- *

- * This program and the accompanying materials are made available under the

- * terms of the Eclipse Public License v. 2.0 which is available at

- * http://www.eclipse.org/legal/epl-2.0.

- *

- * SPDX-License-Identifier: EPL-2.0

- *

- ********************************************************************************/

+/********************************************************************************
+ * Copyright (c) 2015-2018 Contributors to the Eclipse Foundation
+ *
+ * See the NOTICE file(s) distributed with this work for additional
+ * information regarding copyright ownership.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v. 2.0 which is available at
+ * http://www.eclipse.org/legal/epl-2.0.
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ *
+ ********************************************************************************/
 
 
 package org.eclipse.mdm.api.base.model;
@@ -48,7 +48,7 @@
  * @see ParameterSet
  */
 public class Measurement extends BaseEntity
-		implements ContextDescribable, Datable, Deletable, Describable, FilesAttachable, Tagable {
+		implements ContextDescribable, Datable, Deletable, Describable, FilesAttachable, Tagable, StatusAttachable {
 
 	// ======================================================================
 	// Class variables