bkper-js 2.10.1 → 2.10.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.d.ts +6 -0
- package/lib/model/File.js +8 -0
- package/package.json +1 -1
package/lib/index.d.ts
CHANGED
|
@@ -2451,6 +2451,12 @@ export declare enum EventType {
|
|
|
2451
2451
|
export declare class File extends Resource<bkper.File> {
|
|
2452
2452
|
|
|
2453
2453
|
constructor(book: Book, payload?: bkper.File);
|
|
2454
|
+
/**
|
|
2455
|
+
* Gets the Book this File belongs to.
|
|
2456
|
+
*
|
|
2457
|
+
* @returns The Book instance that owns this File
|
|
2458
|
+
*/
|
|
2459
|
+
getBook(): Book;
|
|
2454
2460
|
|
|
2455
2461
|
/**
|
|
2456
2462
|
* Gets the File id.
|
package/lib/model/File.js
CHANGED
|
@@ -22,6 +22,14 @@ export class File extends Resource {
|
|
|
22
22
|
super(payload || { createdAt: `${Date.now()}` });
|
|
23
23
|
this.book = book;
|
|
24
24
|
}
|
|
25
|
+
/**
|
|
26
|
+
* Gets the Book this File belongs to.
|
|
27
|
+
*
|
|
28
|
+
* @returns The Book instance that owns this File
|
|
29
|
+
*/
|
|
30
|
+
getBook() {
|
|
31
|
+
return this.book;
|
|
32
|
+
}
|
|
25
33
|
/** @internal */
|
|
26
34
|
getConfig() {
|
|
27
35
|
return this.book.getConfig();
|