mirror of
https://github.com/LukeHagar/plexjava.git
synced 2025-12-06 20:47:45 +00:00
ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.529.1
This commit is contained in:
1
.gitattributes
vendored
1
.gitattributes
vendored
@@ -9,4 +9,3 @@
|
|||||||
|
|
||||||
# This allows generated code to be indexed correctly
|
# This allows generated code to be indexed correctly
|
||||||
*.java linguist-generated=false
|
*.java linguist-generated=false
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -15,7 +15,7 @@ generation:
|
|||||||
oAuth2ClientCredentialsEnabled: true
|
oAuth2ClientCredentialsEnabled: true
|
||||||
oAuth2PasswordEnabled: false
|
oAuth2PasswordEnabled: false
|
||||||
java:
|
java:
|
||||||
version: 0.14.1
|
version: 0.14.2
|
||||||
additionalDependencies: []
|
additionalDependencies: []
|
||||||
additionalPlugins: []
|
additionalPlugins: []
|
||||||
artifactID: plexapi
|
artifactID: plexapi
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
speakeasyVersion: 1.528.1
|
speakeasyVersion: 1.529.1
|
||||||
sources:
|
sources:
|
||||||
my-source:
|
my-source:
|
||||||
sourceNamespace: my-source
|
sourceNamespace: my-source
|
||||||
@@ -8,19 +8,19 @@ sources:
|
|||||||
- latest
|
- latest
|
||||||
plexapi:
|
plexapi:
|
||||||
sourceNamespace: plexapi
|
sourceNamespace: plexapi
|
||||||
sourceRevisionDigest: sha256:b5580df6ec4a386e12249ff13f35b916fe5559e101de4a816b53e47d6947f1a5
|
sourceRevisionDigest: sha256:ea508e3da23b283f47aeb4384d6b3ab374a27bdffb8d8d8376cedbad3ad77a06
|
||||||
sourceBlobDigest: sha256:6108b6c35fbe7e9163ffe0c804170f5e3a6edb63b8e745454ea8ee249bd790c3
|
sourceBlobDigest: sha256:c210adbd02b0213b9e6f95ffc27f60ec38f8f9040137d55ccf2b650d92ab0ff5
|
||||||
tags:
|
tags:
|
||||||
- latest
|
- latest
|
||||||
- speakeasy-sdk-regen-1743640078
|
- speakeasy-sdk-regen-1743899436
|
||||||
targets:
|
targets:
|
||||||
plexjava:
|
plexjava:
|
||||||
source: plexapi
|
source: plexapi
|
||||||
sourceNamespace: plexapi
|
sourceNamespace: plexapi
|
||||||
sourceRevisionDigest: sha256:b5580df6ec4a386e12249ff13f35b916fe5559e101de4a816b53e47d6947f1a5
|
sourceRevisionDigest: sha256:ea508e3da23b283f47aeb4384d6b3ab374a27bdffb8d8d8376cedbad3ad77a06
|
||||||
sourceBlobDigest: sha256:6108b6c35fbe7e9163ffe0c804170f5e3a6edb63b8e745454ea8ee249bd790c3
|
sourceBlobDigest: sha256:c210adbd02b0213b9e6f95ffc27f60ec38f8f9040137d55ccf2b650d92ab0ff5
|
||||||
codeSamplesNamespace: code-samples-java-plexjava
|
codeSamplesNamespace: code-samples-java-plexjava
|
||||||
codeSamplesRevisionDigest: sha256:5ac1b6e0506bbf85ab353ce21dbf6646b6590efa4ba68ab778ba9836b378e0f6
|
codeSamplesRevisionDigest: sha256:c7bc64aee5441f09dae1f6b15a89c94f6b6065f2e25f5528e849e5ddf2f50d8c
|
||||||
workflow:
|
workflow:
|
||||||
workflowVersion: 1.0.0
|
workflowVersion: 1.0.0
|
||||||
speakeasyVersion: latest
|
speakeasyVersion: latest
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ The samples below show how a published SDK artifact is used:
|
|||||||
|
|
||||||
Gradle:
|
Gradle:
|
||||||
```groovy
|
```groovy
|
||||||
implementation 'dev.plexapi:plexapi:0.14.1'
|
implementation 'dev.plexapi:plexapi:0.14.2'
|
||||||
```
|
```
|
||||||
|
|
||||||
Maven:
|
Maven:
|
||||||
@@ -77,7 +77,7 @@ Maven:
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>dev.plexapi</groupId>
|
<groupId>dev.plexapi</groupId>
|
||||||
<artifactId>plexapi</artifactId>
|
<artifactId>plexapi</artifactId>
|
||||||
<version>0.14.1</version>
|
<version>0.14.2</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
10
RELEASES.md
10
RELEASES.md
@@ -299,3 +299,13 @@ Based on:
|
|||||||
- [java v0.14.1] .
|
- [java v0.14.1] .
|
||||||
### Releases
|
### Releases
|
||||||
- [Maven Central v0.14.1] https://central.sonatype.com/artifact/dev.plexapi/plexapi/0.14.1 - .
|
- [Maven Central v0.14.1] https://central.sonatype.com/artifact/dev.plexapi/plexapi/0.14.1 - .
|
||||||
|
|
||||||
|
## 2025-04-06 00:30:19
|
||||||
|
### Changes
|
||||||
|
Based on:
|
||||||
|
- OpenAPI Doc
|
||||||
|
- Speakeasy CLI 1.529.1 (2.566.5) https://github.com/speakeasy-api/speakeasy
|
||||||
|
### Generated
|
||||||
|
- [java v0.14.2] .
|
||||||
|
### Releases
|
||||||
|
- [Maven Central v0.14.2] https://central.sonatype.com/artifact/dev.plexapi/plexapi/0.14.2 - .
|
||||||
@@ -103,7 +103,7 @@ publishing {
|
|||||||
// https://github.com/gradle/gradle/issues/18619
|
// https://github.com/gradle/gradle/issues/18619
|
||||||
groupId = "dev.plexapi"
|
groupId = "dev.plexapi"
|
||||||
artifactId = "plexapi"
|
artifactId = "plexapi"
|
||||||
version = "0.14.1"
|
version = "0.14.2"
|
||||||
|
|
||||||
from components.java
|
from components.java
|
||||||
|
|
||||||
|
|||||||
712
codeSamples.yaml
712
codeSamples.yaml
File diff suppressed because it is too large
Load Diff
@@ -5,24 +5,24 @@
|
|||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ |
|
| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ |
|
||||||
| `allowSync` | *boolean* | :heavy_check_mark: | N/A | true |
|
| `allowSync` | *boolean* | :heavy_check_mark: | Indicates whether syncing is allowed. | false |
|
||||||
| `art` | *String* | :heavy_check_mark: | N/A | /:/resources/movie-fanart.jpg |
|
| `art` | *String* | :heavy_check_mark: | URL for the background artwork of the media container. | /:/resources/show-fanart.jpg |
|
||||||
| `composite` | *String* | :heavy_check_mark: | N/A | /library/sections/1/composite/1705615584 |
|
| `composite` | *String* | :heavy_check_mark: | The relative path to the composite media item. | /library/sections/1/composite/1743824484 |
|
||||||
| `filters` | *boolean* | :heavy_check_mark: | N/A | true |
|
| `filters` | *boolean* | :heavy_check_mark: | UNKNOWN | true |
|
||||||
| `refreshing` | *boolean* | :heavy_check_mark: | N/A | false |
|
| `refreshing` | *boolean* | :heavy_check_mark: | Indicates whether the library is currently being refreshed or updated | true |
|
||||||
| `thumb` | *String* | :heavy_check_mark: | N/A | /:/resources/movie.png |
|
| `thumb` | *String* | :heavy_check_mark: | URL for the thumbnail image of the media container. | /:/resources/show.png |
|
||||||
| `key` | *String* | :heavy_check_mark: | N/A | 1 |
|
| `key` | *String* | :heavy_check_mark: | The library key representing the unique identifier | 1 |
|
||||||
| `type` | *String* | :heavy_check_mark: | N/A | movie |
|
| `type` | [GetAllLibrariesType](../../models/operations/GetAllLibrariesType.md) | :heavy_check_mark: | N/A | movie |
|
||||||
| `title` | *String* | :heavy_check_mark: | N/A | Movies |
|
| `title` | *String* | :heavy_check_mark: | The title of the library | Movies |
|
||||||
| `agent` | *String* | :heavy_check_mark: | N/A | tv.plex.agents.movie |
|
| `agent` | *String* | :heavy_check_mark: | The Plex agent used to match and retrieve media metadata. | tv.plex.agents.movie |
|
||||||
| `scanner` | *String* | :heavy_check_mark: | N/A | Plex Movie |
|
| `scanner` | *String* | :heavy_check_mark: | UNKNOWN | Plex Movie |
|
||||||
| `language` | *String* | :heavy_check_mark: | N/A | en-US |
|
| `language` | *String* | :heavy_check_mark: | The Plex library language that has been set | en-US |
|
||||||
| `uuid` | *String* | :heavy_check_mark: | N/A | 322a231a-b7f7-49f5-920f-14c61199cd30 |
|
| `uuid` | *String* | :heavy_check_mark: | The universally unique identifier for the library. | e69655a2-ef48-4aba-bb19-01e7d3cc34d6 |
|
||||||
| `updatedAt` | *long* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
| `updatedAt` | *long* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
||||||
| `createdAt` | *long* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
| `createdAt` | *Optional\<Long>* | :heavy_minus_sign: | N/A | 1556281940 |
|
||||||
| `scannedAt` | *long* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
| `scannedAt` | *long* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
||||||
| `content` | *boolean* | :heavy_check_mark: | N/A | true |
|
| `content` | *boolean* | :heavy_check_mark: | UNKNOWN | true |
|
||||||
| `directory` | *boolean* | :heavy_check_mark: | N/A | true |
|
| `directory` | *boolean* | :heavy_check_mark: | UNKNOWN | true |
|
||||||
| `contentChangedAt` | *long* | :heavy_check_mark: | Unix epoch datetime in seconds | 1556281940 |
|
| `contentChangedAt` | *int* | :heavy_check_mark: | The number of seconds since the content was last changed relative to now. | 9173960 |
|
||||||
| `hidden` | *int* | :heavy_check_mark: | N/A | 0 |
|
| `hidden` | [Optional\<Hidden>](../../models/operations/Hidden.md) | :heavy_minus_sign: | N/A | 1 |
|
||||||
| `location` | List\<[GetAllLibrariesLocation](../../models/operations/GetAllLibrariesLocation.md)> | :heavy_check_mark: | N/A | |
|
| `location` | List\<[GetAllLibrariesLocation](../../models/operations/GetAllLibrariesLocation.md)> | :heavy_check_mark: | N/A | |
|
||||||
@@ -4,6 +4,6 @@
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| ------------------ | ------------------ | ------------------ | ------------------ | ------------------ |
|
| --------------------------- | --------------------------- | --------------------------- | --------------------------- | --------------------------- |
|
||||||
| `id` | *int* | :heavy_check_mark: | N/A | 1 |
|
| `id` | *int* | :heavy_check_mark: | The ID of the location. | 1 |
|
||||||
| `path` | *String* | :heavy_check_mark: | N/A | /movies |
|
| `path` | *String* | :heavy_check_mark: | The path to the media item. | /Movies |
|
||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
| Field | Type | Required | Description | Example |
|
| Field | Type | Required | Description | Example |
|
||||||
| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- |
|
| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- |
|
||||||
| `size` | *int* | :heavy_check_mark: | N/A | 5 |
|
| `size` | *int* | :heavy_check_mark: | Number of media items returned in this response. | 50 |
|
||||||
| `allowSync` | *boolean* | :heavy_check_mark: | N/A | false |
|
| `allowSync` | *boolean* | :heavy_check_mark: | Indicates whether syncing is allowed. | false |
|
||||||
| `title1` | *String* | :heavy_check_mark: | N/A | Plex Library |
|
| `title1` | *String* | :heavy_check_mark: | The primary title of the media container. | TV Series |
|
||||||
| `directory` | List\<[GetAllLibrariesDirectory](../../models/operations/GetAllLibrariesDirectory.md)> | :heavy_check_mark: | N/A | |
|
| `directory` | List\<[GetAllLibrariesDirectory](../../models/operations/GetAllLibrariesDirectory.md)> | :heavy_minus_sign: | N/A | |
|
||||||
@@ -6,5 +6,5 @@ The libraries available on the Server
|
|||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
| Field | Type | Required | Description |
|
||||||
| ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- |
|
| ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- |
|
||||||
| `mediaContainer` | [GetAllLibrariesMediaContainer](../../models/operations/GetAllLibrariesMediaContainer.md) | :heavy_check_mark: | N/A |
|
| `mediaContainer` | [Optional\<GetAllLibrariesMediaContainer>](../../models/operations/GetAllLibrariesMediaContainer.md) | :heavy_minus_sign: | N/A |
|
||||||
15
docs/models/operations/GetAllLibrariesType.md
Normal file
15
docs/models/operations/GetAllLibrariesType.md
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# GetAllLibrariesType
|
||||||
|
|
||||||
|
The library type
|
||||||
|
|
||||||
|
|
||||||
|
## Values
|
||||||
|
|
||||||
|
| Name | Value |
|
||||||
|
| --------- | --------- |
|
||||||
|
| `Movie` | movie |
|
||||||
|
| `TvShow` | show |
|
||||||
|
| `Season` | season |
|
||||||
|
| `Episode` | episode |
|
||||||
|
| `Artist` | artist |
|
||||||
|
| `Album` | album |
|
||||||
11
docs/models/operations/Hidden.md
Normal file
11
docs/models/operations/Hidden.md
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
# Hidden
|
||||||
|
|
||||||
|
UNKNOWN
|
||||||
|
|
||||||
|
|
||||||
|
## Values
|
||||||
|
|
||||||
|
| Name | Value |
|
||||||
|
| --------- | --------- |
|
||||||
|
| `Disable` | 0 |
|
||||||
|
| `Enable` | 1 |
|
||||||
@@ -25,7 +25,6 @@ import dev.plexapi.sdk.PlexAPI;
|
|||||||
import dev.plexapi.sdk.models.errors.GetGlobalHubsBadRequest;
|
import dev.plexapi.sdk.models.errors.GetGlobalHubsBadRequest;
|
||||||
import dev.plexapi.sdk.models.errors.GetGlobalHubsUnauthorized;
|
import dev.plexapi.sdk.models.errors.GetGlobalHubsUnauthorized;
|
||||||
import dev.plexapi.sdk.models.operations.GetGlobalHubsResponse;
|
import dev.plexapi.sdk.models.operations.GetGlobalHubsResponse;
|
||||||
import dev.plexapi.sdk.models.operations.OnlyTransient;
|
|
||||||
import java.lang.Exception;
|
import java.lang.Exception;
|
||||||
|
|
||||||
public class Application {
|
public class Application {
|
||||||
@@ -37,8 +36,6 @@ public class Application {
|
|||||||
.build();
|
.build();
|
||||||
|
|
||||||
GetGlobalHubsResponse res = sdk.hubs().getGlobalHubs()
|
GetGlobalHubsResponse res = sdk.hubs().getGlobalHubs()
|
||||||
.count(1262.49)
|
|
||||||
.onlyTransient(OnlyTransient.ONE)
|
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
if (res.object().isPresent()) {
|
if (res.object().isPresent()) {
|
||||||
@@ -136,7 +133,6 @@ import dev.plexapi.sdk.PlexAPI;
|
|||||||
import dev.plexapi.sdk.models.errors.GetLibraryHubsBadRequest;
|
import dev.plexapi.sdk.models.errors.GetLibraryHubsBadRequest;
|
||||||
import dev.plexapi.sdk.models.errors.GetLibraryHubsUnauthorized;
|
import dev.plexapi.sdk.models.errors.GetLibraryHubsUnauthorized;
|
||||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsResponse;
|
import dev.plexapi.sdk.models.operations.GetLibraryHubsResponse;
|
||||||
import dev.plexapi.sdk.models.operations.QueryParamOnlyTransient;
|
|
||||||
import java.lang.Exception;
|
import java.lang.Exception;
|
||||||
|
|
||||||
public class Application {
|
public class Application {
|
||||||
@@ -149,8 +145,6 @@ public class Application {
|
|||||||
|
|
||||||
GetLibraryHubsResponse res = sdk.hubs().getLibraryHubs()
|
GetLibraryHubsResponse res = sdk.hubs().getLibraryHubs()
|
||||||
.sectionId(6728.76)
|
.sectionId(6728.76)
|
||||||
.count(6728.76)
|
|
||||||
.onlyTransient(QueryParamOnlyTransient.ZERO)
|
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
if (res.object().isPresent()) {
|
if (res.object().isPresent()) {
|
||||||
|
|||||||
@@ -54,7 +54,6 @@ public class Application {
|
|||||||
|
|
||||||
GetFileHashResponse res = sdk.library().getFileHash()
|
GetFileHashResponse res = sdk.library().getFileHash()
|
||||||
.url("file://C:\Image.png&type=13")
|
.url("file://C:\Image.png&type=13")
|
||||||
.type(4462.17)
|
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
// handle response
|
// handle response
|
||||||
@@ -257,7 +256,6 @@ import dev.plexapi.sdk.PlexAPI;
|
|||||||
import dev.plexapi.sdk.models.errors.GetLibraryDetailsBadRequest;
|
import dev.plexapi.sdk.models.errors.GetLibraryDetailsBadRequest;
|
||||||
import dev.plexapi.sdk.models.errors.GetLibraryDetailsUnauthorized;
|
import dev.plexapi.sdk.models.errors.GetLibraryDetailsUnauthorized;
|
||||||
import dev.plexapi.sdk.models.operations.GetLibraryDetailsResponse;
|
import dev.plexapi.sdk.models.operations.GetLibraryDetailsResponse;
|
||||||
import dev.plexapi.sdk.models.operations.IncludeDetails;
|
|
||||||
import java.lang.Exception;
|
import java.lang.Exception;
|
||||||
|
|
||||||
public class Application {
|
public class Application {
|
||||||
@@ -269,7 +267,6 @@ public class Application {
|
|||||||
.build();
|
.build();
|
||||||
|
|
||||||
GetLibraryDetailsResponse res = sdk.library().getLibraryDetails()
|
GetLibraryDetailsResponse res = sdk.library().getLibraryDetails()
|
||||||
.includeDetails(IncludeDetails.ZERO)
|
|
||||||
.sectionKey(9518)
|
.sectionKey(9518)
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
@@ -973,7 +970,6 @@ package hello.world;
|
|||||||
import dev.plexapi.sdk.PlexAPI;
|
import dev.plexapi.sdk.PlexAPI;
|
||||||
import dev.plexapi.sdk.models.operations.PostMediaArtsResponse;
|
import dev.plexapi.sdk.models.operations.PostMediaArtsResponse;
|
||||||
import java.lang.Exception;
|
import java.lang.Exception;
|
||||||
import java.nio.charset.StandardCharsets;
|
|
||||||
|
|
||||||
public class Application {
|
public class Application {
|
||||||
|
|
||||||
@@ -986,7 +982,6 @@ public class Application {
|
|||||||
PostMediaArtsResponse res = sdk.library().postMediaArts()
|
PostMediaArtsResponse res = sdk.library().postMediaArts()
|
||||||
.ratingKey(2268L)
|
.ratingKey(2268L)
|
||||||
.url("https://api.mediux.pro/assets/fcfdc487-dd07-4993-a0c1-0a3015362e5b")
|
.url("https://api.mediux.pro/assets/fcfdc487-dd07-4993-a0c1-0a3015362e5b")
|
||||||
.requestBody("0xee51EFC6De".getBytes(StandardCharsets.UTF_8))
|
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
// handle response
|
// handle response
|
||||||
@@ -1072,7 +1067,6 @@ package hello.world;
|
|||||||
import dev.plexapi.sdk.PlexAPI;
|
import dev.plexapi.sdk.PlexAPI;
|
||||||
import dev.plexapi.sdk.models.operations.PostMediaPosterResponse;
|
import dev.plexapi.sdk.models.operations.PostMediaPosterResponse;
|
||||||
import java.lang.Exception;
|
import java.lang.Exception;
|
||||||
import java.nio.charset.StandardCharsets;
|
|
||||||
|
|
||||||
public class Application {
|
public class Application {
|
||||||
|
|
||||||
@@ -1085,7 +1079,6 @@ public class Application {
|
|||||||
PostMediaPosterResponse res = sdk.library().postMediaPoster()
|
PostMediaPosterResponse res = sdk.library().postMediaPoster()
|
||||||
.ratingKey(2268L)
|
.ratingKey(2268L)
|
||||||
.url("https://api.mediux.pro/assets/fcfdc487-dd07-4993-a0c1-0a3015362e5b")
|
.url("https://api.mediux.pro/assets/fcfdc487-dd07-4993-a0c1-0a3015362e5b")
|
||||||
.requestBody("0x7C3d45ad4B".getBytes(StandardCharsets.UTF_8))
|
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
// handle response
|
// handle response
|
||||||
|
|||||||
@@ -95,7 +95,7 @@ package hello.world;
|
|||||||
import dev.plexapi.sdk.PlexAPI;
|
import dev.plexapi.sdk.PlexAPI;
|
||||||
import dev.plexapi.sdk.models.errors.GetPlaylistsBadRequest;
|
import dev.plexapi.sdk.models.errors.GetPlaylistsBadRequest;
|
||||||
import dev.plexapi.sdk.models.errors.GetPlaylistsUnauthorized;
|
import dev.plexapi.sdk.models.errors.GetPlaylistsUnauthorized;
|
||||||
import dev.plexapi.sdk.models.operations.*;
|
import dev.plexapi.sdk.models.operations.GetPlaylistsResponse;
|
||||||
import java.lang.Exception;
|
import java.lang.Exception;
|
||||||
|
|
||||||
public class Application {
|
public class Application {
|
||||||
@@ -107,8 +107,6 @@ public class Application {
|
|||||||
.build();
|
.build();
|
||||||
|
|
||||||
GetPlaylistsResponse res = sdk.playlists().getPlaylists()
|
GetPlaylistsResponse res = sdk.playlists().getPlaylists()
|
||||||
.playlistType(PlaylistType.AUDIO)
|
|
||||||
.smart(QueryParamSmart.ZERO)
|
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
if (res.object().isPresent()) {
|
if (res.object().isPresent()) {
|
||||||
@@ -268,8 +266,6 @@ public class Application {
|
|||||||
|
|
||||||
UpdatePlaylistResponse res = sdk.playlists().updatePlaylist()
|
UpdatePlaylistResponse res = sdk.playlists().updatePlaylist()
|
||||||
.playlistID(3915)
|
.playlistID(3915)
|
||||||
.title("<value>")
|
|
||||||
.summary("<value>")
|
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
// handle response
|
// handle response
|
||||||
|
|||||||
@@ -225,7 +225,7 @@ package hello.world;
|
|||||||
import dev.plexapi.sdk.PlexAPI;
|
import dev.plexapi.sdk.PlexAPI;
|
||||||
import dev.plexapi.sdk.models.errors.GetServerResourcesBadRequest;
|
import dev.plexapi.sdk.models.errors.GetServerResourcesBadRequest;
|
||||||
import dev.plexapi.sdk.models.errors.GetServerResourcesUnauthorized;
|
import dev.plexapi.sdk.models.errors.GetServerResourcesUnauthorized;
|
||||||
import dev.plexapi.sdk.models.operations.*;
|
import dev.plexapi.sdk.models.operations.GetServerResourcesResponse;
|
||||||
import java.lang.Exception;
|
import java.lang.Exception;
|
||||||
|
|
||||||
public class Application {
|
public class Application {
|
||||||
@@ -237,9 +237,6 @@ public class Application {
|
|||||||
.build();
|
.build();
|
||||||
|
|
||||||
GetServerResourcesResponse res = sdk.plex().getServerResources()
|
GetServerResourcesResponse res = sdk.plex().getServerResources()
|
||||||
.includeHttps(IncludeHttps.Enable)
|
|
||||||
.includeRelay(IncludeRelay.Enable)
|
|
||||||
.includeIPv6(IncludeIPv6.Enable)
|
|
||||||
.clientID("3381b62b-9ab7-4e37-827b-203e9809eb58")
|
.clientID("3381b62b-9ab7-4e37-827b-203e9809eb58")
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
|
|||||||
@@ -49,8 +49,6 @@ public class Application {
|
|||||||
|
|
||||||
PerformSearchResponse res = sdk.search().performSearch()
|
PerformSearchResponse res = sdk.search().performSearch()
|
||||||
.query("dylan")
|
.query("dylan")
|
||||||
.sectionId(9487.88)
|
|
||||||
.limit(5)
|
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
// handle response
|
// handle response
|
||||||
@@ -107,8 +105,6 @@ public class Application {
|
|||||||
|
|
||||||
PerformVoiceSearchResponse res = sdk.search().performVoiceSearch()
|
PerformVoiceSearchResponse res = sdk.search().performVoiceSearch()
|
||||||
.query("dead+poop")
|
.query("dead+poop")
|
||||||
.sectionId(4094.8)
|
|
||||||
.limit(5)
|
|
||||||
.call();
|
.call();
|
||||||
|
|
||||||
// handle response
|
// handle response
|
||||||
|
|||||||
@@ -1,3 +1,3 @@
|
|||||||
groupId=dev.plexapi
|
groupId=dev.plexapi
|
||||||
artifactId=plexapi
|
artifactId=plexapi
|
||||||
version=0.14.1
|
version=0.14.2
|
||||||
@@ -52,7 +52,7 @@ public class PlexAPI {
|
|||||||
/**
|
/**
|
||||||
* The full address of your Plex Server
|
* The full address of your Plex Server
|
||||||
*/
|
*/
|
||||||
"{protocol}://{ip}:{port}",
|
"https://10.10.10.47:32400",
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -508,4 +508,5 @@ public class PlexAPI {
|
|||||||
this.updater = new Updater(sdkConfiguration);
|
this.updater = new Updater(sdkConfiguration);
|
||||||
this.users = new Users(sdkConfiguration);
|
this.users = new Users(sdkConfiguration);
|
||||||
this.sdkConfiguration.initialize();
|
this.sdkConfiguration.initialize();
|
||||||
}}
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -42,8 +42,8 @@ class SDKConfiguration {
|
|||||||
} };
|
} };
|
||||||
private static final String LANGUAGE = "java";
|
private static final String LANGUAGE = "java";
|
||||||
public static final String OPENAPI_DOC_VERSION = "0.0.3";
|
public static final String OPENAPI_DOC_VERSION = "0.0.3";
|
||||||
public static final String SDK_VERSION = "0.14.1";
|
public static final String SDK_VERSION = "0.14.2";
|
||||||
public static final String GEN_VERSION = "2.565.1";
|
public static final String GEN_VERSION = "2.566.5";
|
||||||
private static final String BASE_PACKAGE = "dev.plexapi.sdk";
|
private static final String BASE_PACKAGE = "dev.plexapi.sdk";
|
||||||
public static final String USER_AGENT =
|
public static final String USER_AGENT =
|
||||||
String.format("speakeasy-sdk/%s %s %s %s %s",
|
String.format("speakeasy-sdk/%s %s %s %s %s",
|
||||||
|
|||||||
@@ -5,54 +5,96 @@ package dev.plexapi.sdk.models.operations;
|
|||||||
|
|
||||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude.Include;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
import com.fasterxml.jackson.core.type.TypeReference;
|
||||||
|
import dev.plexapi.sdk.utils.LazySingletonValue;
|
||||||
import dev.plexapi.sdk.utils.Utils;
|
import dev.plexapi.sdk.utils.Utils;
|
||||||
import java.lang.Boolean;
|
import java.lang.Boolean;
|
||||||
import java.lang.Integer;
|
import java.lang.Integer;
|
||||||
import java.lang.Long;
|
import java.lang.Long;
|
||||||
import java.lang.Override;
|
import java.lang.Override;
|
||||||
import java.lang.String;
|
import java.lang.String;
|
||||||
|
import java.lang.SuppressWarnings;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Optional;
|
||||||
|
|
||||||
public class GetAllLibrariesDirectory {
|
public class GetAllLibrariesDirectory {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether syncing is allowed.
|
||||||
|
*/
|
||||||
@JsonProperty("allowSync")
|
@JsonProperty("allowSync")
|
||||||
private boolean allowSync;
|
private boolean allowSync;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* URL for the background artwork of the media container.
|
||||||
|
*/
|
||||||
@JsonProperty("art")
|
@JsonProperty("art")
|
||||||
private String art;
|
private String art;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The relative path to the composite media item.
|
||||||
|
*/
|
||||||
@JsonProperty("composite")
|
@JsonProperty("composite")
|
||||||
private String composite;
|
private String composite;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
@JsonProperty("filters")
|
@JsonProperty("filters")
|
||||||
private boolean filters;
|
private boolean filters;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether the library is currently being refreshed or updated
|
||||||
|
*/
|
||||||
@JsonProperty("refreshing")
|
@JsonProperty("refreshing")
|
||||||
private boolean refreshing;
|
private boolean refreshing;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* URL for the thumbnail image of the media container.
|
||||||
|
*/
|
||||||
@JsonProperty("thumb")
|
@JsonProperty("thumb")
|
||||||
private String thumb;
|
private String thumb;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The library key representing the unique identifier
|
||||||
|
*/
|
||||||
@JsonProperty("key")
|
@JsonProperty("key")
|
||||||
private String key;
|
private String key;
|
||||||
|
|
||||||
@JsonProperty("type")
|
@JsonProperty("type")
|
||||||
private String type;
|
private GetAllLibrariesType type;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The title of the library
|
||||||
|
*/
|
||||||
@JsonProperty("title")
|
@JsonProperty("title")
|
||||||
private String title;
|
private String title;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Plex agent used to match and retrieve media metadata.
|
||||||
|
*/
|
||||||
@JsonProperty("agent")
|
@JsonProperty("agent")
|
||||||
private String agent;
|
private String agent;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
@JsonProperty("scanner")
|
@JsonProperty("scanner")
|
||||||
private String scanner;
|
private String scanner;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Plex library language that has been set
|
||||||
|
*/
|
||||||
@JsonProperty("language")
|
@JsonProperty("language")
|
||||||
private String language;
|
private String language;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The universally unique identifier for the library.
|
||||||
|
*/
|
||||||
@JsonProperty("uuid")
|
@JsonProperty("uuid")
|
||||||
private String uuid;
|
private String uuid;
|
||||||
|
|
||||||
@@ -62,11 +104,9 @@ public class GetAllLibrariesDirectory {
|
|||||||
@JsonProperty("updatedAt")
|
@JsonProperty("updatedAt")
|
||||||
private long updatedAt;
|
private long updatedAt;
|
||||||
|
|
||||||
/**
|
@JsonInclude(Include.NON_ABSENT)
|
||||||
* Unix epoch datetime in seconds
|
|
||||||
*/
|
|
||||||
@JsonProperty("createdAt")
|
@JsonProperty("createdAt")
|
||||||
private long createdAt;
|
private Optional<Long> createdAt;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Unix epoch datetime in seconds
|
* Unix epoch datetime in seconds
|
||||||
@@ -74,20 +114,27 @@ public class GetAllLibrariesDirectory {
|
|||||||
@JsonProperty("scannedAt")
|
@JsonProperty("scannedAt")
|
||||||
private long scannedAt;
|
private long scannedAt;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
@JsonProperty("content")
|
@JsonProperty("content")
|
||||||
private boolean content;
|
private boolean content;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
@JsonProperty("directory")
|
@JsonProperty("directory")
|
||||||
private boolean directory;
|
private boolean directory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Unix epoch datetime in seconds
|
* The number of seconds since the content was last changed relative to now.
|
||||||
*/
|
*/
|
||||||
@JsonProperty("contentChangedAt")
|
@JsonProperty("contentChangedAt")
|
||||||
private long contentChangedAt;
|
private int contentChangedAt;
|
||||||
|
|
||||||
|
@JsonInclude(Include.NON_ABSENT)
|
||||||
@JsonProperty("hidden")
|
@JsonProperty("hidden")
|
||||||
private int hidden;
|
private Optional<? extends Hidden> hidden;
|
||||||
|
|
||||||
@JsonProperty("Location")
|
@JsonProperty("Location")
|
||||||
private List<GetAllLibrariesLocation> location;
|
private List<GetAllLibrariesLocation> location;
|
||||||
@@ -101,19 +148,19 @@ public class GetAllLibrariesDirectory {
|
|||||||
@JsonProperty("refreshing") boolean refreshing,
|
@JsonProperty("refreshing") boolean refreshing,
|
||||||
@JsonProperty("thumb") String thumb,
|
@JsonProperty("thumb") String thumb,
|
||||||
@JsonProperty("key") String key,
|
@JsonProperty("key") String key,
|
||||||
@JsonProperty("type") String type,
|
@JsonProperty("type") GetAllLibrariesType type,
|
||||||
@JsonProperty("title") String title,
|
@JsonProperty("title") String title,
|
||||||
@JsonProperty("agent") String agent,
|
@JsonProperty("agent") String agent,
|
||||||
@JsonProperty("scanner") String scanner,
|
@JsonProperty("scanner") String scanner,
|
||||||
@JsonProperty("language") String language,
|
@JsonProperty("language") String language,
|
||||||
@JsonProperty("uuid") String uuid,
|
@JsonProperty("uuid") String uuid,
|
||||||
@JsonProperty("updatedAt") long updatedAt,
|
@JsonProperty("updatedAt") long updatedAt,
|
||||||
@JsonProperty("createdAt") long createdAt,
|
@JsonProperty("createdAt") Optional<Long> createdAt,
|
||||||
@JsonProperty("scannedAt") long scannedAt,
|
@JsonProperty("scannedAt") long scannedAt,
|
||||||
@JsonProperty("content") boolean content,
|
@JsonProperty("content") boolean content,
|
||||||
@JsonProperty("directory") boolean directory,
|
@JsonProperty("directory") boolean directory,
|
||||||
@JsonProperty("contentChangedAt") long contentChangedAt,
|
@JsonProperty("contentChangedAt") int contentChangedAt,
|
||||||
@JsonProperty("hidden") int hidden,
|
@JsonProperty("hidden") Optional<? extends Hidden> hidden,
|
||||||
@JsonProperty("Location") List<GetAllLibrariesLocation> location) {
|
@JsonProperty("Location") List<GetAllLibrariesLocation> location) {
|
||||||
Utils.checkNotNull(allowSync, "allowSync");
|
Utils.checkNotNull(allowSync, "allowSync");
|
||||||
Utils.checkNotNull(art, "art");
|
Utils.checkNotNull(art, "art");
|
||||||
@@ -159,66 +206,125 @@ public class GetAllLibrariesDirectory {
|
|||||||
this.location = location;
|
this.location = location;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public GetAllLibrariesDirectory(
|
||||||
|
boolean allowSync,
|
||||||
|
String art,
|
||||||
|
String composite,
|
||||||
|
boolean filters,
|
||||||
|
boolean refreshing,
|
||||||
|
String thumb,
|
||||||
|
String key,
|
||||||
|
GetAllLibrariesType type,
|
||||||
|
String title,
|
||||||
|
String agent,
|
||||||
|
String scanner,
|
||||||
|
String language,
|
||||||
|
String uuid,
|
||||||
|
long updatedAt,
|
||||||
|
long scannedAt,
|
||||||
|
boolean content,
|
||||||
|
boolean directory,
|
||||||
|
int contentChangedAt,
|
||||||
|
List<GetAllLibrariesLocation> location) {
|
||||||
|
this(allowSync, art, composite, filters, refreshing, thumb, key, type, title, agent, scanner, language, uuid, updatedAt, Optional.empty(), scannedAt, content, directory, contentChangedAt, Optional.empty(), location);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether syncing is allowed.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public boolean allowSync() {
|
public boolean allowSync() {
|
||||||
return allowSync;
|
return allowSync;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* URL for the background artwork of the media container.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String art() {
|
public String art() {
|
||||||
return art;
|
return art;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The relative path to the composite media item.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String composite() {
|
public String composite() {
|
||||||
return composite;
|
return composite;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public boolean filters() {
|
public boolean filters() {
|
||||||
return filters;
|
return filters;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether the library is currently being refreshed or updated
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public boolean refreshing() {
|
public boolean refreshing() {
|
||||||
return refreshing;
|
return refreshing;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* URL for the thumbnail image of the media container.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String thumb() {
|
public String thumb() {
|
||||||
return thumb;
|
return thumb;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The library key representing the unique identifier
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String key() {
|
public String key() {
|
||||||
return key;
|
return key;
|
||||||
}
|
}
|
||||||
|
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String type() {
|
public GetAllLibrariesType type() {
|
||||||
return type;
|
return type;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The title of the library
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String title() {
|
public String title() {
|
||||||
return title;
|
return title;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Plex agent used to match and retrieve media metadata.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String agent() {
|
public String agent() {
|
||||||
return agent;
|
return agent;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String scanner() {
|
public String scanner() {
|
||||||
return scanner;
|
return scanner;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Plex library language that has been set
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String language() {
|
public String language() {
|
||||||
return language;
|
return language;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The universally unique identifier for the library.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String uuid() {
|
public String uuid() {
|
||||||
return uuid;
|
return uuid;
|
||||||
@@ -232,11 +338,8 @@ public class GetAllLibrariesDirectory {
|
|||||||
return updatedAt;
|
return updatedAt;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Unix epoch datetime in seconds
|
|
||||||
*/
|
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public long createdAt() {
|
public Optional<Long> createdAt() {
|
||||||
return createdAt;
|
return createdAt;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -248,27 +351,34 @@ public class GetAllLibrariesDirectory {
|
|||||||
return scannedAt;
|
return scannedAt;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public boolean content() {
|
public boolean content() {
|
||||||
return content;
|
return content;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public boolean directory() {
|
public boolean directory() {
|
||||||
return directory;
|
return directory;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Unix epoch datetime in seconds
|
* The number of seconds since the content was last changed relative to now.
|
||||||
*/
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public long contentChangedAt() {
|
public int contentChangedAt() {
|
||||||
return contentChangedAt;
|
return contentChangedAt;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public int hidden() {
|
public Optional<Hidden> hidden() {
|
||||||
return hidden;
|
return (Optional<Hidden>) hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
@@ -280,78 +390,114 @@ public class GetAllLibrariesDirectory {
|
|||||||
return new Builder();
|
return new Builder();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether syncing is allowed.
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withAllowSync(boolean allowSync) {
|
public GetAllLibrariesDirectory withAllowSync(boolean allowSync) {
|
||||||
Utils.checkNotNull(allowSync, "allowSync");
|
Utils.checkNotNull(allowSync, "allowSync");
|
||||||
this.allowSync = allowSync;
|
this.allowSync = allowSync;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* URL for the background artwork of the media container.
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withArt(String art) {
|
public GetAllLibrariesDirectory withArt(String art) {
|
||||||
Utils.checkNotNull(art, "art");
|
Utils.checkNotNull(art, "art");
|
||||||
this.art = art;
|
this.art = art;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The relative path to the composite media item.
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withComposite(String composite) {
|
public GetAllLibrariesDirectory withComposite(String composite) {
|
||||||
Utils.checkNotNull(composite, "composite");
|
Utils.checkNotNull(composite, "composite");
|
||||||
this.composite = composite;
|
this.composite = composite;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withFilters(boolean filters) {
|
public GetAllLibrariesDirectory withFilters(boolean filters) {
|
||||||
Utils.checkNotNull(filters, "filters");
|
Utils.checkNotNull(filters, "filters");
|
||||||
this.filters = filters;
|
this.filters = filters;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether the library is currently being refreshed or updated
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withRefreshing(boolean refreshing) {
|
public GetAllLibrariesDirectory withRefreshing(boolean refreshing) {
|
||||||
Utils.checkNotNull(refreshing, "refreshing");
|
Utils.checkNotNull(refreshing, "refreshing");
|
||||||
this.refreshing = refreshing;
|
this.refreshing = refreshing;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* URL for the thumbnail image of the media container.
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withThumb(String thumb) {
|
public GetAllLibrariesDirectory withThumb(String thumb) {
|
||||||
Utils.checkNotNull(thumb, "thumb");
|
Utils.checkNotNull(thumb, "thumb");
|
||||||
this.thumb = thumb;
|
this.thumb = thumb;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The library key representing the unique identifier
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withKey(String key) {
|
public GetAllLibrariesDirectory withKey(String key) {
|
||||||
Utils.checkNotNull(key, "key");
|
Utils.checkNotNull(key, "key");
|
||||||
this.key = key;
|
this.key = key;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public GetAllLibrariesDirectory withType(String type) {
|
public GetAllLibrariesDirectory withType(GetAllLibrariesType type) {
|
||||||
Utils.checkNotNull(type, "type");
|
Utils.checkNotNull(type, "type");
|
||||||
this.type = type;
|
this.type = type;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The title of the library
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withTitle(String title) {
|
public GetAllLibrariesDirectory withTitle(String title) {
|
||||||
Utils.checkNotNull(title, "title");
|
Utils.checkNotNull(title, "title");
|
||||||
this.title = title;
|
this.title = title;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Plex agent used to match and retrieve media metadata.
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withAgent(String agent) {
|
public GetAllLibrariesDirectory withAgent(String agent) {
|
||||||
Utils.checkNotNull(agent, "agent");
|
Utils.checkNotNull(agent, "agent");
|
||||||
this.agent = agent;
|
this.agent = agent;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withScanner(String scanner) {
|
public GetAllLibrariesDirectory withScanner(String scanner) {
|
||||||
Utils.checkNotNull(scanner, "scanner");
|
Utils.checkNotNull(scanner, "scanner");
|
||||||
this.scanner = scanner;
|
this.scanner = scanner;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Plex library language that has been set
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withLanguage(String language) {
|
public GetAllLibrariesDirectory withLanguage(String language) {
|
||||||
Utils.checkNotNull(language, "language");
|
Utils.checkNotNull(language, "language");
|
||||||
this.language = language;
|
this.language = language;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The universally unique identifier for the library.
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withUuid(String uuid) {
|
public GetAllLibrariesDirectory withUuid(String uuid) {
|
||||||
Utils.checkNotNull(uuid, "uuid");
|
Utils.checkNotNull(uuid, "uuid");
|
||||||
this.uuid = uuid;
|
this.uuid = uuid;
|
||||||
@@ -367,10 +513,13 @@ public class GetAllLibrariesDirectory {
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Unix epoch datetime in seconds
|
|
||||||
*/
|
|
||||||
public GetAllLibrariesDirectory withCreatedAt(long createdAt) {
|
public GetAllLibrariesDirectory withCreatedAt(long createdAt) {
|
||||||
|
Utils.checkNotNull(createdAt, "createdAt");
|
||||||
|
this.createdAt = Optional.ofNullable(createdAt);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public GetAllLibrariesDirectory withCreatedAt(Optional<Long> createdAt) {
|
||||||
Utils.checkNotNull(createdAt, "createdAt");
|
Utils.checkNotNull(createdAt, "createdAt");
|
||||||
this.createdAt = createdAt;
|
this.createdAt = createdAt;
|
||||||
return this;
|
return this;
|
||||||
@@ -385,12 +534,18 @@ public class GetAllLibrariesDirectory {
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withContent(boolean content) {
|
public GetAllLibrariesDirectory withContent(boolean content) {
|
||||||
Utils.checkNotNull(content, "content");
|
Utils.checkNotNull(content, "content");
|
||||||
this.content = content;
|
this.content = content;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
public GetAllLibrariesDirectory withDirectory(boolean directory) {
|
public GetAllLibrariesDirectory withDirectory(boolean directory) {
|
||||||
Utils.checkNotNull(directory, "directory");
|
Utils.checkNotNull(directory, "directory");
|
||||||
this.directory = directory;
|
this.directory = directory;
|
||||||
@@ -398,15 +553,21 @@ public class GetAllLibrariesDirectory {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Unix epoch datetime in seconds
|
* The number of seconds since the content was last changed relative to now.
|
||||||
*/
|
*/
|
||||||
public GetAllLibrariesDirectory withContentChangedAt(long contentChangedAt) {
|
public GetAllLibrariesDirectory withContentChangedAt(int contentChangedAt) {
|
||||||
Utils.checkNotNull(contentChangedAt, "contentChangedAt");
|
Utils.checkNotNull(contentChangedAt, "contentChangedAt");
|
||||||
this.contentChangedAt = contentChangedAt;
|
this.contentChangedAt = contentChangedAt;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public GetAllLibrariesDirectory withHidden(int hidden) {
|
public GetAllLibrariesDirectory withHidden(Hidden hidden) {
|
||||||
|
Utils.checkNotNull(hidden, "hidden");
|
||||||
|
this.hidden = Optional.ofNullable(hidden);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public GetAllLibrariesDirectory withHidden(Optional<? extends Hidden> hidden) {
|
||||||
Utils.checkNotNull(hidden, "hidden");
|
Utils.checkNotNull(hidden, "hidden");
|
||||||
this.hidden = hidden;
|
this.hidden = hidden;
|
||||||
return this;
|
return this;
|
||||||
@@ -520,7 +681,7 @@ public class GetAllLibrariesDirectory {
|
|||||||
|
|
||||||
private String key;
|
private String key;
|
||||||
|
|
||||||
private String type;
|
private GetAllLibrariesType type;
|
||||||
|
|
||||||
private String title;
|
private String title;
|
||||||
|
|
||||||
@@ -534,7 +695,7 @@ public class GetAllLibrariesDirectory {
|
|||||||
|
|
||||||
private Long updatedAt;
|
private Long updatedAt;
|
||||||
|
|
||||||
private Long createdAt;
|
private Optional<Long> createdAt = Optional.empty();
|
||||||
|
|
||||||
private Long scannedAt;
|
private Long scannedAt;
|
||||||
|
|
||||||
@@ -542,9 +703,9 @@ public class GetAllLibrariesDirectory {
|
|||||||
|
|
||||||
private Boolean directory;
|
private Boolean directory;
|
||||||
|
|
||||||
private Long contentChangedAt;
|
private Integer contentChangedAt;
|
||||||
|
|
||||||
private Integer hidden;
|
private Optional<? extends Hidden> hidden;
|
||||||
|
|
||||||
private List<GetAllLibrariesLocation> location;
|
private List<GetAllLibrariesLocation> location;
|
||||||
|
|
||||||
@@ -552,78 +713,114 @@ public class GetAllLibrariesDirectory {
|
|||||||
// force use of static builder() method
|
// force use of static builder() method
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether syncing is allowed.
|
||||||
|
*/
|
||||||
public Builder allowSync(boolean allowSync) {
|
public Builder allowSync(boolean allowSync) {
|
||||||
Utils.checkNotNull(allowSync, "allowSync");
|
Utils.checkNotNull(allowSync, "allowSync");
|
||||||
this.allowSync = allowSync;
|
this.allowSync = allowSync;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* URL for the background artwork of the media container.
|
||||||
|
*/
|
||||||
public Builder art(String art) {
|
public Builder art(String art) {
|
||||||
Utils.checkNotNull(art, "art");
|
Utils.checkNotNull(art, "art");
|
||||||
this.art = art;
|
this.art = art;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The relative path to the composite media item.
|
||||||
|
*/
|
||||||
public Builder composite(String composite) {
|
public Builder composite(String composite) {
|
||||||
Utils.checkNotNull(composite, "composite");
|
Utils.checkNotNull(composite, "composite");
|
||||||
this.composite = composite;
|
this.composite = composite;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
public Builder filters(boolean filters) {
|
public Builder filters(boolean filters) {
|
||||||
Utils.checkNotNull(filters, "filters");
|
Utils.checkNotNull(filters, "filters");
|
||||||
this.filters = filters;
|
this.filters = filters;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether the library is currently being refreshed or updated
|
||||||
|
*/
|
||||||
public Builder refreshing(boolean refreshing) {
|
public Builder refreshing(boolean refreshing) {
|
||||||
Utils.checkNotNull(refreshing, "refreshing");
|
Utils.checkNotNull(refreshing, "refreshing");
|
||||||
this.refreshing = refreshing;
|
this.refreshing = refreshing;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* URL for the thumbnail image of the media container.
|
||||||
|
*/
|
||||||
public Builder thumb(String thumb) {
|
public Builder thumb(String thumb) {
|
||||||
Utils.checkNotNull(thumb, "thumb");
|
Utils.checkNotNull(thumb, "thumb");
|
||||||
this.thumb = thumb;
|
this.thumb = thumb;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The library key representing the unique identifier
|
||||||
|
*/
|
||||||
public Builder key(String key) {
|
public Builder key(String key) {
|
||||||
Utils.checkNotNull(key, "key");
|
Utils.checkNotNull(key, "key");
|
||||||
this.key = key;
|
this.key = key;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Builder type(String type) {
|
public Builder type(GetAllLibrariesType type) {
|
||||||
Utils.checkNotNull(type, "type");
|
Utils.checkNotNull(type, "type");
|
||||||
this.type = type;
|
this.type = type;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The title of the library
|
||||||
|
*/
|
||||||
public Builder title(String title) {
|
public Builder title(String title) {
|
||||||
Utils.checkNotNull(title, "title");
|
Utils.checkNotNull(title, "title");
|
||||||
this.title = title;
|
this.title = title;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Plex agent used to match and retrieve media metadata.
|
||||||
|
*/
|
||||||
public Builder agent(String agent) {
|
public Builder agent(String agent) {
|
||||||
Utils.checkNotNull(agent, "agent");
|
Utils.checkNotNull(agent, "agent");
|
||||||
this.agent = agent;
|
this.agent = agent;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
public Builder scanner(String scanner) {
|
public Builder scanner(String scanner) {
|
||||||
Utils.checkNotNull(scanner, "scanner");
|
Utils.checkNotNull(scanner, "scanner");
|
||||||
this.scanner = scanner;
|
this.scanner = scanner;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Plex library language that has been set
|
||||||
|
*/
|
||||||
public Builder language(String language) {
|
public Builder language(String language) {
|
||||||
Utils.checkNotNull(language, "language");
|
Utils.checkNotNull(language, "language");
|
||||||
this.language = language;
|
this.language = language;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The universally unique identifier for the library.
|
||||||
|
*/
|
||||||
public Builder uuid(String uuid) {
|
public Builder uuid(String uuid) {
|
||||||
Utils.checkNotNull(uuid, "uuid");
|
Utils.checkNotNull(uuid, "uuid");
|
||||||
this.uuid = uuid;
|
this.uuid = uuid;
|
||||||
@@ -639,10 +836,13 @@ public class GetAllLibrariesDirectory {
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Unix epoch datetime in seconds
|
|
||||||
*/
|
|
||||||
public Builder createdAt(long createdAt) {
|
public Builder createdAt(long createdAt) {
|
||||||
|
Utils.checkNotNull(createdAt, "createdAt");
|
||||||
|
this.createdAt = Optional.ofNullable(createdAt);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Builder createdAt(Optional<Long> createdAt) {
|
||||||
Utils.checkNotNull(createdAt, "createdAt");
|
Utils.checkNotNull(createdAt, "createdAt");
|
||||||
this.createdAt = createdAt;
|
this.createdAt = createdAt;
|
||||||
return this;
|
return this;
|
||||||
@@ -657,12 +857,18 @@ public class GetAllLibrariesDirectory {
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
public Builder content(boolean content) {
|
public Builder content(boolean content) {
|
||||||
Utils.checkNotNull(content, "content");
|
Utils.checkNotNull(content, "content");
|
||||||
this.content = content;
|
this.content = content;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* UNKNOWN
|
||||||
|
*/
|
||||||
public Builder directory(boolean directory) {
|
public Builder directory(boolean directory) {
|
||||||
Utils.checkNotNull(directory, "directory");
|
Utils.checkNotNull(directory, "directory");
|
||||||
this.directory = directory;
|
this.directory = directory;
|
||||||
@@ -670,15 +876,21 @@ public class GetAllLibrariesDirectory {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Unix epoch datetime in seconds
|
* The number of seconds since the content was last changed relative to now.
|
||||||
*/
|
*/
|
||||||
public Builder contentChangedAt(long contentChangedAt) {
|
public Builder contentChangedAt(int contentChangedAt) {
|
||||||
Utils.checkNotNull(contentChangedAt, "contentChangedAt");
|
Utils.checkNotNull(contentChangedAt, "contentChangedAt");
|
||||||
this.contentChangedAt = contentChangedAt;
|
this.contentChangedAt = contentChangedAt;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Builder hidden(int hidden) {
|
public Builder hidden(Hidden hidden) {
|
||||||
|
Utils.checkNotNull(hidden, "hidden");
|
||||||
|
this.hidden = Optional.ofNullable(hidden);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Builder hidden(Optional<? extends Hidden> hidden) {
|
||||||
Utils.checkNotNull(hidden, "hidden");
|
Utils.checkNotNull(hidden, "hidden");
|
||||||
this.hidden = hidden;
|
this.hidden = hidden;
|
||||||
return this;
|
return this;
|
||||||
@@ -691,6 +903,9 @@ public class GetAllLibrariesDirectory {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public GetAllLibrariesDirectory build() {
|
public GetAllLibrariesDirectory build() {
|
||||||
|
if (hidden == null) {
|
||||||
|
hidden = _SINGLETON_VALUE_Hidden.value();
|
||||||
|
}
|
||||||
return new GetAllLibrariesDirectory(
|
return new GetAllLibrariesDirectory(
|
||||||
allowSync,
|
allowSync,
|
||||||
art,
|
art,
|
||||||
@@ -714,5 +929,11 @@ public class GetAllLibrariesDirectory {
|
|||||||
hidden,
|
hidden,
|
||||||
location);
|
location);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static final LazySingletonValue<Optional<? extends Hidden>> _SINGLETON_VALUE_Hidden =
|
||||||
|
new LazySingletonValue<>(
|
||||||
|
"hidden",
|
||||||
|
"0",
|
||||||
|
new TypeReference<Optional<? extends Hidden>>() {});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,9 +14,15 @@ import java.util.Objects;
|
|||||||
|
|
||||||
public class GetAllLibrariesLocation {
|
public class GetAllLibrariesLocation {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The ID of the location.
|
||||||
|
*/
|
||||||
@JsonProperty("id")
|
@JsonProperty("id")
|
||||||
private int id;
|
private int id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The path to the media item.
|
||||||
|
*/
|
||||||
@JsonProperty("path")
|
@JsonProperty("path")
|
||||||
private String path;
|
private String path;
|
||||||
|
|
||||||
@@ -30,11 +36,17 @@ public class GetAllLibrariesLocation {
|
|||||||
this.path = path;
|
this.path = path;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The ID of the location.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public int id() {
|
public int id() {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The path to the media item.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String path() {
|
public String path() {
|
||||||
return path;
|
return path;
|
||||||
@@ -44,12 +56,18 @@ public class GetAllLibrariesLocation {
|
|||||||
return new Builder();
|
return new Builder();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The ID of the location.
|
||||||
|
*/
|
||||||
public GetAllLibrariesLocation withId(int id) {
|
public GetAllLibrariesLocation withId(int id) {
|
||||||
Utils.checkNotNull(id, "id");
|
Utils.checkNotNull(id, "id");
|
||||||
this.id = id;
|
this.id = id;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The path to the media item.
|
||||||
|
*/
|
||||||
public GetAllLibrariesLocation withPath(String path) {
|
public GetAllLibrariesLocation withPath(String path) {
|
||||||
Utils.checkNotNull(path, "path");
|
Utils.checkNotNull(path, "path");
|
||||||
this.path = path;
|
this.path = path;
|
||||||
@@ -95,12 +113,18 @@ public class GetAllLibrariesLocation {
|
|||||||
// force use of static builder() method
|
// force use of static builder() method
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The ID of the location.
|
||||||
|
*/
|
||||||
public Builder id(int id) {
|
public Builder id(int id) {
|
||||||
Utils.checkNotNull(id, "id");
|
Utils.checkNotNull(id, "id");
|
||||||
this.id = id;
|
this.id = id;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The path to the media item.
|
||||||
|
*/
|
||||||
public Builder path(String path) {
|
public Builder path(String path) {
|
||||||
Utils.checkNotNull(path, "path");
|
Utils.checkNotNull(path, "path");
|
||||||
this.path = path;
|
this.path = path;
|
||||||
|
|||||||
@@ -5,35 +5,49 @@ package dev.plexapi.sdk.models.operations;
|
|||||||
|
|
||||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude.Include;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
import dev.plexapi.sdk.utils.Utils;
|
import dev.plexapi.sdk.utils.Utils;
|
||||||
import java.lang.Boolean;
|
import java.lang.Boolean;
|
||||||
import java.lang.Integer;
|
import java.lang.Integer;
|
||||||
import java.lang.Override;
|
import java.lang.Override;
|
||||||
import java.lang.String;
|
import java.lang.String;
|
||||||
|
import java.lang.SuppressWarnings;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Optional;
|
||||||
|
|
||||||
public class GetAllLibrariesMediaContainer {
|
public class GetAllLibrariesMediaContainer {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Number of media items returned in this response.
|
||||||
|
*/
|
||||||
@JsonProperty("size")
|
@JsonProperty("size")
|
||||||
private int size;
|
private int size;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether syncing is allowed.
|
||||||
|
*/
|
||||||
@JsonProperty("allowSync")
|
@JsonProperty("allowSync")
|
||||||
private boolean allowSync;
|
private boolean allowSync;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The primary title of the media container.
|
||||||
|
*/
|
||||||
@JsonProperty("title1")
|
@JsonProperty("title1")
|
||||||
private String title1;
|
private String title1;
|
||||||
|
|
||||||
|
@JsonInclude(Include.NON_ABSENT)
|
||||||
@JsonProperty("Directory")
|
@JsonProperty("Directory")
|
||||||
private List<GetAllLibrariesDirectory> directory;
|
private Optional<? extends List<GetAllLibrariesDirectory>> directory;
|
||||||
|
|
||||||
@JsonCreator
|
@JsonCreator
|
||||||
public GetAllLibrariesMediaContainer(
|
public GetAllLibrariesMediaContainer(
|
||||||
@JsonProperty("size") int size,
|
@JsonProperty("size") int size,
|
||||||
@JsonProperty("allowSync") boolean allowSync,
|
@JsonProperty("allowSync") boolean allowSync,
|
||||||
@JsonProperty("title1") String title1,
|
@JsonProperty("title1") String title1,
|
||||||
@JsonProperty("Directory") List<GetAllLibrariesDirectory> directory) {
|
@JsonProperty("Directory") Optional<? extends List<GetAllLibrariesDirectory>> directory) {
|
||||||
Utils.checkNotNull(size, "size");
|
Utils.checkNotNull(size, "size");
|
||||||
Utils.checkNotNull(allowSync, "allowSync");
|
Utils.checkNotNull(allowSync, "allowSync");
|
||||||
Utils.checkNotNull(title1, "title1");
|
Utils.checkNotNull(title1, "title1");
|
||||||
@@ -44,42 +58,68 @@ public class GetAllLibrariesMediaContainer {
|
|||||||
this.directory = directory;
|
this.directory = directory;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public GetAllLibrariesMediaContainer(
|
||||||
|
int size,
|
||||||
|
boolean allowSync,
|
||||||
|
String title1) {
|
||||||
|
this(size, allowSync, title1, Optional.empty());
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Number of media items returned in this response.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public int size() {
|
public int size() {
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether syncing is allowed.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public boolean allowSync() {
|
public boolean allowSync() {
|
||||||
return allowSync;
|
return allowSync;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The primary title of the media container.
|
||||||
|
*/
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public String title1() {
|
public String title1() {
|
||||||
return title1;
|
return title1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public List<GetAllLibrariesDirectory> directory() {
|
public Optional<List<GetAllLibrariesDirectory>> directory() {
|
||||||
return directory;
|
return (Optional<List<GetAllLibrariesDirectory>>) directory;
|
||||||
}
|
}
|
||||||
|
|
||||||
public final static Builder builder() {
|
public final static Builder builder() {
|
||||||
return new Builder();
|
return new Builder();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Number of media items returned in this response.
|
||||||
|
*/
|
||||||
public GetAllLibrariesMediaContainer withSize(int size) {
|
public GetAllLibrariesMediaContainer withSize(int size) {
|
||||||
Utils.checkNotNull(size, "size");
|
Utils.checkNotNull(size, "size");
|
||||||
this.size = size;
|
this.size = size;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether syncing is allowed.
|
||||||
|
*/
|
||||||
public GetAllLibrariesMediaContainer withAllowSync(boolean allowSync) {
|
public GetAllLibrariesMediaContainer withAllowSync(boolean allowSync) {
|
||||||
Utils.checkNotNull(allowSync, "allowSync");
|
Utils.checkNotNull(allowSync, "allowSync");
|
||||||
this.allowSync = allowSync;
|
this.allowSync = allowSync;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The primary title of the media container.
|
||||||
|
*/
|
||||||
public GetAllLibrariesMediaContainer withTitle1(String title1) {
|
public GetAllLibrariesMediaContainer withTitle1(String title1) {
|
||||||
Utils.checkNotNull(title1, "title1");
|
Utils.checkNotNull(title1, "title1");
|
||||||
this.title1 = title1;
|
this.title1 = title1;
|
||||||
@@ -87,6 +127,12 @@ public class GetAllLibrariesMediaContainer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public GetAllLibrariesMediaContainer withDirectory(List<GetAllLibrariesDirectory> directory) {
|
public GetAllLibrariesMediaContainer withDirectory(List<GetAllLibrariesDirectory> directory) {
|
||||||
|
Utils.checkNotNull(directory, "directory");
|
||||||
|
this.directory = Optional.ofNullable(directory);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public GetAllLibrariesMediaContainer withDirectory(Optional<? extends List<GetAllLibrariesDirectory>> directory) {
|
||||||
Utils.checkNotNull(directory, "directory");
|
Utils.checkNotNull(directory, "directory");
|
||||||
this.directory = directory;
|
this.directory = directory;
|
||||||
return this;
|
return this;
|
||||||
@@ -135,24 +181,33 @@ public class GetAllLibrariesMediaContainer {
|
|||||||
|
|
||||||
private String title1;
|
private String title1;
|
||||||
|
|
||||||
private List<GetAllLibrariesDirectory> directory;
|
private Optional<? extends List<GetAllLibrariesDirectory>> directory = Optional.empty();
|
||||||
|
|
||||||
private Builder() {
|
private Builder() {
|
||||||
// force use of static builder() method
|
// force use of static builder() method
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Number of media items returned in this response.
|
||||||
|
*/
|
||||||
public Builder size(int size) {
|
public Builder size(int size) {
|
||||||
Utils.checkNotNull(size, "size");
|
Utils.checkNotNull(size, "size");
|
||||||
this.size = size;
|
this.size = size;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Indicates whether syncing is allowed.
|
||||||
|
*/
|
||||||
public Builder allowSync(boolean allowSync) {
|
public Builder allowSync(boolean allowSync) {
|
||||||
Utils.checkNotNull(allowSync, "allowSync");
|
Utils.checkNotNull(allowSync, "allowSync");
|
||||||
this.allowSync = allowSync;
|
this.allowSync = allowSync;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The primary title of the media container.
|
||||||
|
*/
|
||||||
public Builder title1(String title1) {
|
public Builder title1(String title1) {
|
||||||
Utils.checkNotNull(title1, "title1");
|
Utils.checkNotNull(title1, "title1");
|
||||||
this.title1 = title1;
|
this.title1 = title1;
|
||||||
@@ -160,6 +215,12 @@ public class GetAllLibrariesMediaContainer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public Builder directory(List<GetAllLibrariesDirectory> directory) {
|
public Builder directory(List<GetAllLibrariesDirectory> directory) {
|
||||||
|
Utils.checkNotNull(directory, "directory");
|
||||||
|
this.directory = Optional.ofNullable(directory);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Builder directory(Optional<? extends List<GetAllLibrariesDirectory>> directory) {
|
||||||
Utils.checkNotNull(directory, "directory");
|
Utils.checkNotNull(directory, "directory");
|
||||||
this.directory = directory;
|
this.directory = directory;
|
||||||
return this;
|
return this;
|
||||||
|
|||||||
@@ -5,11 +5,15 @@ package dev.plexapi.sdk.models.operations;
|
|||||||
|
|
||||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude.Include;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
import dev.plexapi.sdk.utils.Utils;
|
import dev.plexapi.sdk.utils.Utils;
|
||||||
import java.lang.Override;
|
import java.lang.Override;
|
||||||
import java.lang.String;
|
import java.lang.String;
|
||||||
|
import java.lang.SuppressWarnings;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
import java.util.Optional;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* GetAllLibrariesResponseBody
|
* GetAllLibrariesResponseBody
|
||||||
@@ -18,19 +22,25 @@ import java.util.Objects;
|
|||||||
*/
|
*/
|
||||||
public class GetAllLibrariesResponseBody {
|
public class GetAllLibrariesResponseBody {
|
||||||
|
|
||||||
|
@JsonInclude(Include.NON_ABSENT)
|
||||||
@JsonProperty("MediaContainer")
|
@JsonProperty("MediaContainer")
|
||||||
private GetAllLibrariesMediaContainer mediaContainer;
|
private Optional<? extends GetAllLibrariesMediaContainer> mediaContainer;
|
||||||
|
|
||||||
@JsonCreator
|
@JsonCreator
|
||||||
public GetAllLibrariesResponseBody(
|
public GetAllLibrariesResponseBody(
|
||||||
@JsonProperty("MediaContainer") GetAllLibrariesMediaContainer mediaContainer) {
|
@JsonProperty("MediaContainer") Optional<? extends GetAllLibrariesMediaContainer> mediaContainer) {
|
||||||
Utils.checkNotNull(mediaContainer, "mediaContainer");
|
Utils.checkNotNull(mediaContainer, "mediaContainer");
|
||||||
this.mediaContainer = mediaContainer;
|
this.mediaContainer = mediaContainer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public GetAllLibrariesResponseBody() {
|
||||||
|
this(Optional.empty());
|
||||||
|
}
|
||||||
|
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
public GetAllLibrariesMediaContainer mediaContainer() {
|
public Optional<GetAllLibrariesMediaContainer> mediaContainer() {
|
||||||
return mediaContainer;
|
return (Optional<GetAllLibrariesMediaContainer>) mediaContainer;
|
||||||
}
|
}
|
||||||
|
|
||||||
public final static Builder builder() {
|
public final static Builder builder() {
|
||||||
@@ -38,6 +48,12 @@ public class GetAllLibrariesResponseBody {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public GetAllLibrariesResponseBody withMediaContainer(GetAllLibrariesMediaContainer mediaContainer) {
|
public GetAllLibrariesResponseBody withMediaContainer(GetAllLibrariesMediaContainer mediaContainer) {
|
||||||
|
Utils.checkNotNull(mediaContainer, "mediaContainer");
|
||||||
|
this.mediaContainer = Optional.ofNullable(mediaContainer);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public GetAllLibrariesResponseBody withMediaContainer(Optional<? extends GetAllLibrariesMediaContainer> mediaContainer) {
|
||||||
Utils.checkNotNull(mediaContainer, "mediaContainer");
|
Utils.checkNotNull(mediaContainer, "mediaContainer");
|
||||||
this.mediaContainer = mediaContainer;
|
this.mediaContainer = mediaContainer;
|
||||||
return this;
|
return this;
|
||||||
@@ -71,13 +87,19 @@ public class GetAllLibrariesResponseBody {
|
|||||||
|
|
||||||
public final static class Builder {
|
public final static class Builder {
|
||||||
|
|
||||||
private GetAllLibrariesMediaContainer mediaContainer;
|
private Optional<? extends GetAllLibrariesMediaContainer> mediaContainer = Optional.empty();
|
||||||
|
|
||||||
private Builder() {
|
private Builder() {
|
||||||
// force use of static builder() method
|
// force use of static builder() method
|
||||||
}
|
}
|
||||||
|
|
||||||
public Builder mediaContainer(GetAllLibrariesMediaContainer mediaContainer) {
|
public Builder mediaContainer(GetAllLibrariesMediaContainer mediaContainer) {
|
||||||
|
Utils.checkNotNull(mediaContainer, "mediaContainer");
|
||||||
|
this.mediaContainer = Optional.ofNullable(mediaContainer);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Builder mediaContainer(Optional<? extends GetAllLibrariesMediaContainer> mediaContainer) {
|
||||||
Utils.checkNotNull(mediaContainer, "mediaContainer");
|
Utils.checkNotNull(mediaContainer, "mediaContainer");
|
||||||
this.mediaContainer = mediaContainer;
|
this.mediaContainer = mediaContainer;
|
||||||
return this;
|
return this;
|
||||||
|
|||||||
@@ -0,0 +1,44 @@
|
|||||||
|
/*
|
||||||
|
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||||
|
*/
|
||||||
|
package dev.plexapi.sdk.models.operations;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonValue;
|
||||||
|
import java.lang.String;
|
||||||
|
import java.util.Objects;
|
||||||
|
import java.util.Optional;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* GetAllLibrariesType
|
||||||
|
*
|
||||||
|
* <p>The library type
|
||||||
|
*/
|
||||||
|
public enum GetAllLibrariesType {
|
||||||
|
Movie("movie"),
|
||||||
|
TvShow("show"),
|
||||||
|
Season("season"),
|
||||||
|
Episode("episode"),
|
||||||
|
Artist("artist"),
|
||||||
|
Album("album");
|
||||||
|
|
||||||
|
@JsonValue
|
||||||
|
private final String value;
|
||||||
|
|
||||||
|
private GetAllLibrariesType(String value) {
|
||||||
|
this.value = value;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String value() {
|
||||||
|
return value;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Optional<GetAllLibrariesType> fromValue(String value) {
|
||||||
|
for (GetAllLibrariesType o: GetAllLibrariesType.values()) {
|
||||||
|
if (Objects.deepEquals(o.value, value)) {
|
||||||
|
return Optional.of(o);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return Optional.empty();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
39
src/main/java/dev/plexapi/sdk/models/operations/Hidden.java
Normal file
39
src/main/java/dev/plexapi/sdk/models/operations/Hidden.java
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
/*
|
||||||
|
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||||
|
*/
|
||||||
|
package dev.plexapi.sdk.models.operations;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonValue;
|
||||||
|
import java.util.Objects;
|
||||||
|
import java.util.Optional;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Hidden
|
||||||
|
*
|
||||||
|
* <p>UNKNOWN
|
||||||
|
*/
|
||||||
|
public enum Hidden {
|
||||||
|
Disable(0),
|
||||||
|
Enable(1);
|
||||||
|
|
||||||
|
@JsonValue
|
||||||
|
private final int value;
|
||||||
|
|
||||||
|
private Hidden(int value) {
|
||||||
|
this.value = value;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int value() {
|
||||||
|
return value;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Optional<Hidden> fromValue(int value) {
|
||||||
|
for (Hidden o: Hidden.values()) {
|
||||||
|
if (Objects.deepEquals(o.value, value)) {
|
||||||
|
return Optional.of(o);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return Optional.empty();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@@ -158,8 +158,8 @@ public final class SessionManager<T extends SessionManager.HasSessionKey> {
|
|||||||
if (!t.tokenType.orElse("").equals("Bearer")) {
|
if (!t.tokenType.orElse("").equals("Bearer")) {
|
||||||
throw new AuthException("Expected 'Bearer' token type but was '" + t.tokenType.orElse("") + "'");
|
throw new AuthException("Expected 'Bearer' token type but was '" + t.tokenType.orElse("") + "'");
|
||||||
}
|
}
|
||||||
final Optional<OffsetDateTime> expiresAt = t.expiresInMs
|
final Optional<OffsetDateTime> expiresAt = t.expiresInSeconds
|
||||||
.map(x -> OffsetDateTime.now().plus(x, ChronoUnit.MILLIS));
|
.map(x -> OffsetDateTime.now().plus(x, ChronoUnit.SECONDS));
|
||||||
return new Session<T>(credentials, t.accessToken, scopes, expiresAt);
|
return new Session<T>(credentials, t.accessToken, scopes, expiresAt);
|
||||||
} catch (IOException | IllegalArgumentException | IllegalAccessException | InterruptedException | URISyntaxException e) {
|
} catch (IOException | IllegalArgumentException | IllegalAccessException | InterruptedException | URISyntaxException e) {
|
||||||
throw new RuntimeException(e);
|
throw new RuntimeException(e);
|
||||||
@@ -175,7 +175,7 @@ public final class SessionManager<T extends SessionManager.HasSessionKey> {
|
|||||||
Optional<String> tokenType;
|
Optional<String> tokenType;
|
||||||
|
|
||||||
@JsonProperty("expires_in")
|
@JsonProperty("expires_in")
|
||||||
Optional<Long> expiresInMs;
|
Optional<Long> expiresInSeconds;;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user