Skip to content

Commit

Permalink
#325 - Add width and height standard metadata properties
Browse files Browse the repository at this point in the history
  • Loading branch information
mfriesen committed Feb 7, 2025
1 parent e6e28cb commit faf39b7
Show file tree
Hide file tree
Showing 21 changed files with 744 additions and 42 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,20 @@ public interface DocumentItem {
*/
String getDeepLinkPath();

/**
* Get Width.
*
* @return {@link String}
*/
String getWidth();

/**
* Get Height.
*
* @return {@link String}
*/
String getHeight();

/**
* Get Document Id.
*
Expand Down Expand Up @@ -184,6 +198,20 @@ public interface DocumentItem {
*/
void setDeepLinkPath(String deepLinkPath);

/**
* Set Width.
*
* @param width {@link String}
*/
void setWidth(String width);

/**
* Set Height.
*
* @param height {@link String}
*/
void setHeight(String height);

/**
* Set Document ID.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,16 @@ public String getDeepLinkPath() {
return getString("deepLinkPath");
}

@Override
public String getWidth() {
return getString("width");
}

@Override
public String getHeight() {
return getString("height");
}

@Override
public String getDocumentId() {
return getString("documentId");
Expand All @@ -102,7 +112,6 @@ public Date getLastModifiedDate() {
return getDate("lastModifiedDate");
}

@SuppressWarnings("unchecked")
@Override
public Collection<DocumentMetadata> getMetadata() {
Collection<Map<String, Object>> c =
Expand All @@ -112,7 +121,7 @@ public Collection<DocumentMetadata> getMetadata() {

if (c != null) {
metadata = c.stream().map(m -> {
DocumentMetadata md = null;
DocumentMetadata md;
if (m.containsKey("values")) {
md = new DocumentMetadata((String) m.get("key"), (List<String>) m.get("values"));
} else {
Expand Down Expand Up @@ -180,6 +189,16 @@ public void setDeepLinkPath(final String deepLinkPath) {
put("deepLinkPath", deepLinkPath);
}

@Override
public void setWidth(final String width) {
put("width", width);
}

@Override
public void setHeight(final String height) {
put("height", height);
}

@Override
public void setDocumentId(final String documentId) {
put("documentId", documentId);
Expand Down
78 changes: 78 additions & 0 deletions docs/openapi/openapi-iam.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6893,6 +6893,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -6943,6 +6949,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -7228,6 +7240,12 @@
contentType:
type: string
description: Document media type
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -7273,6 +7291,12 @@
checksum:
type: string
description: The checksum value to validate the file against
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -7316,6 +7340,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -7620,6 +7650,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -7816,6 +7852,12 @@
contentType:
type: string
description: Document Content-Type
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -7897,6 +7939,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -8086,6 +8134,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -8152,6 +8206,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -9607,6 +9667,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -9646,6 +9712,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down Expand Up @@ -9685,6 +9757,12 @@
path:
type: string
description: Path or Name of document
width:
type: string
description: Document Content Width property
height:
type: string
description: Document Content Height property
deepLinkPath:
type: string
description: Path or Name of deep link
Expand Down
Loading

0 comments on commit faf39b7

Please sign in to comment.