Skip to content

Commit

Permalink
Created a mimetype message and added it to ListSupportedMimeTypesResp…
Browse files Browse the repository at this point in the history
…onse
  • Loading branch information
glpatcern committed Sep 10, 2021
1 parent 8639343 commit 47593f6
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 2 deletions.
7 changes: 5 additions & 2 deletions cs3/app/registry/v1beta1/registry_api.proto
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,11 @@ message ListSupportedMimeTypesResponse {
// Opaque information.
cs3.types.v1beta1.Opaque opaque = 2;
// REQUIRED.
// The list of supported mime types with the apps which they can be opened with.
map<string, AppProviderList> mime_types = 3;
// The list of supported mime types and their properties.
MimeTypeList mime_types = 3;
// REQUIRED.
// The list of supported apps indexed by mime type.
map<string, AppProviderList> apps = 4;
}

message GetDefaultAppProviderForMimeTypeRequest {
Expand Down
21 changes: 21 additions & 0 deletions cs3/app/registry/v1beta1/resources.proto
Original file line number Diff line number Diff line change
Expand Up @@ -72,3 +72,24 @@ message ProviderInfo {
message AppProviderList {
repeated ProviderInfo app_providers = 1;
}

// Represents a mime type and its corresponding file extension.
message MimeType {
// OPTIONAL.
// Opaque information.
cs3.types.v1beta1.Opaque opaque = 1;
// REQUIRED.
// The mime type.
string mime_type = 2;
// REQUIRED.
// The friendly name of this mime type.
string name = 3;
// REQUIRED.
// The file extension mapped to this mime type.
string ext = 4;
}

// Holds a list of mime types.
message MimeTypeList {
repeated MimeType mime_types = 1;
}

0 comments on commit 47593f6

Please sign in to comment.