triangle-types 1.0.69 → 1.0.71

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.
@@ -28,10 +28,12 @@ export * from "./types/federal_lobby/FederalLobbyLobbyist.js";
28
28
  export * from "./types/federal_lobby/FederalLobbyDocument.js";
29
29
  export * from "./types/federal_lobby/FederalLobbyDocumentInterest.js";
30
30
  export * from "./types/federal_congress/FederalCongressBill.js";
31
+ export * from "./types/federal_congress/FederalCongressBillAction.js";
31
32
  export * from "./types/federal_congress/FederalCongressBillDocument.js";
32
33
  export * from "./types/federal_congress/FederalCongressCommittee.js";
33
34
  export * from "./types/federal_congress/FederalCongressDistrict.js";
34
35
  export * from "./types/federal_congress/FederalCongressMember.js";
36
+ export * from "./types/federal_congress/FederalCongressVote.js";
35
37
  export * from "./types/federal_register/FederalRegisterAgency.js";
36
38
  export * from "./types/federal_register/FederalRegisterDocument.js";
37
39
  export * from "./types/federal_dockets/FederalDocketAgency.js";
package/dist/src/index.js CHANGED
@@ -28,10 +28,12 @@ export * from "./types/federal_lobby/FederalLobbyLobbyist.js";
28
28
  export * from "./types/federal_lobby/FederalLobbyDocument.js";
29
29
  export * from "./types/federal_lobby/FederalLobbyDocumentInterest.js";
30
30
  export * from "./types/federal_congress/FederalCongressBill.js";
31
+ export * from "./types/federal_congress/FederalCongressBillAction.js";
31
32
  export * from "./types/federal_congress/FederalCongressBillDocument.js";
32
33
  export * from "./types/federal_congress/FederalCongressCommittee.js";
33
34
  export * from "./types/federal_congress/FederalCongressDistrict.js";
34
35
  export * from "./types/federal_congress/FederalCongressMember.js";
36
+ export * from "./types/federal_congress/FederalCongressVote.js";
35
37
  export * from "./types/federal_register/FederalRegisterAgency.js";
36
38
  export * from "./types/federal_register/FederalRegisterDocument.js";
37
39
  export * from "./types/federal_dockets/FederalDocketAgency.js";
@@ -0,0 +1,21 @@
1
+ import { FederalCongressBillTypeID } from "./FederalCongressBill.js";
2
+ declare const federal_congress_bill_action_type_ids: readonly ["COMMITTEE", "CALENDARS", "FLOOR", "BECAMELAW", "INTROREFERRAL", "PRESIDENT", "RESOLVINGDIFFERENCES", "DISCHARGE", "NOTUSED", "VETO"];
3
+ export type FederalCongressBillActionTypeID = typeof federal_congress_bill_action_type_ids[number];
4
+ export declare function is_federal_congress_bill_action_type_id(federal_congress_bill_action_type_id: any): federal_congress_bill_action_type_id is FederalCongressBillActionTypeID;
5
+ export declare class FederalCongressBillAction {
6
+ readonly federal_congress_bill_action_id: string;
7
+ readonly federal_congress_bill_id: string;
8
+ readonly action_id: number;
9
+ readonly federal_congress_id: number;
10
+ readonly bill_id: string;
11
+ readonly bill_type_id: FederalCongressBillTypeID;
12
+ readonly number: number;
13
+ readonly bill_action_type_id: FederalCongressBillActionTypeID;
14
+ readonly date: string;
15
+ readonly description: string;
16
+ readonly federal_congress_committee_ids: string[];
17
+ readonly federal_congress_vote_ids: string[];
18
+ constructor(federal_congress_bill_action: any);
19
+ static is(federal_congress_bill_action: any): federal_congress_bill_action is FederalCongressBillAction;
20
+ }
21
+ export {};
@@ -0,0 +1,61 @@
1
+ const federal_congress_bill_action_type_ids = [
2
+ "COMMITTEE",
3
+ "CALENDARS",
4
+ "FLOOR",
5
+ "BECAMELAW",
6
+ "INTROREFERRAL",
7
+ "PRESIDENT",
8
+ "RESOLVINGDIFFERENCES",
9
+ "DISCHARGE",
10
+ "NOTUSED",
11
+ "VETO"
12
+ ];
13
+ export function is_federal_congress_bill_action_type_id(federal_congress_bill_action_type_id) {
14
+ return federal_congress_bill_action_type_ids.includes(federal_congress_bill_action_type_id);
15
+ }
16
+ export class FederalCongressBillAction {
17
+ federal_congress_bill_action_id;
18
+ federal_congress_bill_id;
19
+ action_id;
20
+ federal_congress_id;
21
+ bill_id;
22
+ bill_type_id;
23
+ number;
24
+ bill_action_type_id;
25
+ date;
26
+ description;
27
+ federal_congress_committee_ids;
28
+ federal_congress_vote_ids;
29
+ constructor(federal_congress_bill_action) {
30
+ if (!FederalCongressBillAction.is(federal_congress_bill_action)) {
31
+ throw Error("Invalid input.");
32
+ }
33
+ this.federal_congress_bill_action_id = federal_congress_bill_action.federal_congress_bill_action_id;
34
+ this.federal_congress_bill_id = federal_congress_bill_action.federal_congress_bill_id;
35
+ this.federal_congress_id = federal_congress_bill_action.federal_congress_id;
36
+ this.bill_id = federal_congress_bill_action.bill_id;
37
+ this.bill_type_id = federal_congress_bill_action.bill_type_id;
38
+ this.number = federal_congress_bill_action.number;
39
+ this.action_id = federal_congress_bill_action.action_id;
40
+ this.bill_action_type_id = federal_congress_bill_action.bill_action_type_id;
41
+ this.date = federal_congress_bill_action.date;
42
+ this.description = federal_congress_bill_action.description;
43
+ this.federal_congress_committee_ids = federal_congress_bill_action.federal_congress_committee_ids;
44
+ this.federal_congress_vote_ids = federal_congress_bill_action.federal_congress_vote_ids;
45
+ }
46
+ static is(federal_congress_bill_action) {
47
+ return (federal_congress_bill_action !== undefined &&
48
+ typeof federal_congress_bill_action.federal_congress_bill_action_id === "string" &&
49
+ typeof federal_congress_bill_action.federal_congress_bill_id === "string" &&
50
+ typeof federal_congress_bill_action.federal_congress_id === "number" &&
51
+ typeof federal_congress_bill_action.bill_id === "string" &&
52
+ typeof federal_congress_bill_action.bill_type_id === "string" &&
53
+ typeof federal_congress_bill_action.number === "number" &&
54
+ typeof federal_congress_bill_action.action_id === "string" &&
55
+ is_federal_congress_bill_action_type_id(federal_congress_bill_action.bill_action_type_id) &&
56
+ typeof federal_congress_bill_action.date === "string" &&
57
+ typeof federal_congress_bill_action.description === "string" &&
58
+ (Array.isArray(federal_congress_bill_action.federal_congress_committee_ids) && federal_congress_bill_action.federal_congress_committee_ids.every((federal_congress_committee_id) => typeof federal_congress_committee_id === "string")) &&
59
+ (Array.isArray(federal_congress_bill_action.federal_congress_vote_ids) && federal_congress_bill_action.federal_congress_vote_ids.every((federal_congress_vote_id) => typeof federal_congress_vote_id === "string")));
60
+ }
61
+ }
@@ -13,6 +13,7 @@ export declare class FederalCongressBillDocument {
13
13
  readonly bill_document_type_id: FederalCongressBillDocumentTypeID;
14
14
  readonly format_id: string;
15
15
  readonly publish_time?: string;
16
+ readonly url: string;
16
17
  readonly s3_id?: string;
17
18
  constructor(federal_congress_bill_document: any);
18
19
  static is(federal_congress_bill_document: any): federal_congress_bill_document is FederalCongressBillDocument;
@@ -15,6 +15,7 @@ export class FederalCongressBillDocument {
15
15
  bill_document_type_id;
16
16
  format_id;
17
17
  publish_time;
18
+ url;
18
19
  s3_id;
19
20
  constructor(federal_congress_bill_document) {
20
21
  if (!FederalCongressBillDocument.is(federal_congress_bill_document)) {
@@ -30,6 +31,7 @@ export class FederalCongressBillDocument {
30
31
  this.bill_document_type_id = federal_congress_bill_document.bill_document_type_id;
31
32
  this.format_id = federal_congress_bill_document.format_id;
32
33
  this.publish_time = federal_congress_bill_document.publish_time;
34
+ this.url = federal_congress_bill_document.url;
33
35
  this.s3_id = federal_congress_bill_document.s3_id;
34
36
  }
35
37
  static is(federal_congress_bill_document) {
@@ -44,6 +46,7 @@ export class FederalCongressBillDocument {
44
46
  is_federal_congress_bill_document_type_id(federal_congress_bill_document.bill_document_type_id) &&
45
47
  typeof federal_congress_bill_document.format_id === "string" &&
46
48
  (federal_congress_bill_document.publish_time === undefined || typeof federal_congress_bill_document.publish_time === "string") &&
49
+ typeof federal_congress_bill_document.url === "string" &&
47
50
  (federal_congress_bill_document.s3_id === undefined || typeof federal_congress_bill_document.s3_id === "string"));
48
51
  }
49
52
  }
@@ -0,0 +1,10 @@
1
+ export declare class FederalCongressVote {
2
+ readonly federal_congress_vote_id: string;
3
+ readonly federal_congress_id: number;
4
+ readonly session_id: number;
5
+ readonly chamber_id: string;
6
+ readonly number: number;
7
+ readonly date: string;
8
+ constructor(federal_congress_vote: any);
9
+ static is(federal_congress_vote: any): federal_congress_vote is FederalCongressVote;
10
+ }
@@ -0,0 +1,28 @@
1
+ export class FederalCongressVote {
2
+ federal_congress_vote_id;
3
+ federal_congress_id;
4
+ session_id;
5
+ chamber_id;
6
+ number;
7
+ date;
8
+ constructor(federal_congress_vote) {
9
+ if (!FederalCongressVote.is(federal_congress_vote)) {
10
+ throw Error("Invalid input.");
11
+ }
12
+ this.federal_congress_vote_id = federal_congress_vote.federal_congress_vote_id;
13
+ this.federal_congress_id = federal_congress_vote.federal_congress_id;
14
+ this.session_id = federal_congress_vote.session_id;
15
+ this.chamber_id = federal_congress_vote.chamber_id;
16
+ this.number = federal_congress_vote.number;
17
+ this.date = federal_congress_vote.date;
18
+ }
19
+ static is(federal_congress_vote) {
20
+ return (federal_congress_vote !== undefined &&
21
+ typeof federal_congress_vote.federal_congress_vote_id === "string" &&
22
+ typeof federal_congress_vote.federal_congress_id === "number" &&
23
+ typeof federal_congress_vote.session_id === "number" &&
24
+ typeof federal_congress_vote.chamber_id === "string" &&
25
+ typeof federal_congress_vote.number === "number" &&
26
+ typeof federal_congress_vote.date === "string");
27
+ }
28
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "triangle-types",
3
- "version": "1.0.69",
3
+ "version": "1.0.71",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "scripts": {
package/src/index.ts CHANGED
@@ -32,10 +32,12 @@ export * from "./types/federal_lobby/FederalLobbyDocument"
32
32
  export * from "./types/federal_lobby/FederalLobbyDocumentInterest"
33
33
 
34
34
  export * from "./types/federal_congress/FederalCongressBill"
35
+ export * from "./types/federal_congress/FederalCongressBillAction"
35
36
  export * from "./types/federal_congress/FederalCongressBillDocument"
36
37
  export * from "./types/federal_congress/FederalCongressCommittee"
37
38
  export * from "./types/federal_congress/FederalCongressDistrict"
38
39
  export * from "./types/federal_congress/FederalCongressMember"
40
+ export * from "./types/federal_congress/FederalCongressVote"
39
41
 
40
42
  export * from "./types/federal_register/FederalRegisterAgency"
41
43
  export * from "./types/federal_register/FederalRegisterDocument"
@@ -0,0 +1,72 @@
1
+ import { FederalCongressBillTypeID } from "./FederalCongressBill"
2
+
3
+ const federal_congress_bill_action_type_ids = [
4
+ "COMMITTEE",
5
+ "CALENDARS",
6
+ "FLOOR",
7
+ "BECAMELAW",
8
+ "INTROREFERRAL",
9
+ "PRESIDENT",
10
+ "RESOLVINGDIFFERENCES",
11
+ "DISCHARGE",
12
+ "NOTUSED",
13
+ "VETO"
14
+ ] as const
15
+
16
+ export type FederalCongressBillActionTypeID = typeof federal_congress_bill_action_type_ids[number]
17
+
18
+ export function is_federal_congress_bill_action_type_id(federal_congress_bill_action_type_id : any) : federal_congress_bill_action_type_id is FederalCongressBillActionTypeID {
19
+ return federal_congress_bill_action_type_ids.includes(federal_congress_bill_action_type_id)
20
+ }
21
+
22
+ export class FederalCongressBillAction {
23
+ readonly federal_congress_bill_action_id : string
24
+ readonly federal_congress_bill_id : string
25
+ readonly action_id : number
26
+ readonly federal_congress_id : number
27
+ readonly bill_id : string
28
+ readonly bill_type_id : FederalCongressBillTypeID
29
+ readonly number : number
30
+ readonly bill_action_type_id : FederalCongressBillActionTypeID
31
+ readonly date : string
32
+ readonly description : string
33
+ readonly federal_congress_committee_ids : string[]
34
+ readonly federal_congress_vote_ids : string[]
35
+
36
+ constructor(federal_congress_bill_action : any) {
37
+ if (!FederalCongressBillAction.is(federal_congress_bill_action)) {
38
+ throw Error("Invalid input.")
39
+ }
40
+ this.federal_congress_bill_action_id = federal_congress_bill_action.federal_congress_bill_action_id
41
+ this.federal_congress_bill_id = federal_congress_bill_action.federal_congress_bill_id
42
+ this.federal_congress_id = federal_congress_bill_action.federal_congress_id
43
+ this.bill_id = federal_congress_bill_action.bill_id
44
+ this.bill_type_id = federal_congress_bill_action.bill_type_id
45
+ this.number = federal_congress_bill_action.number
46
+ this.action_id = federal_congress_bill_action.action_id
47
+ this.bill_action_type_id = federal_congress_bill_action.bill_action_type_id
48
+ this.date = federal_congress_bill_action.date
49
+ this.description = federal_congress_bill_action.description
50
+ this.federal_congress_committee_ids = federal_congress_bill_action.federal_congress_committee_ids
51
+ this.federal_congress_vote_ids = federal_congress_bill_action.federal_congress_vote_ids
52
+ }
53
+
54
+ static is(federal_congress_bill_action : any) : federal_congress_bill_action is FederalCongressBillAction {
55
+ return (
56
+ federal_congress_bill_action !== undefined &&
57
+ typeof federal_congress_bill_action.federal_congress_bill_action_id === "string" &&
58
+ typeof federal_congress_bill_action.federal_congress_bill_id === "string" &&
59
+ typeof federal_congress_bill_action.federal_congress_id === "number" &&
60
+ typeof federal_congress_bill_action.bill_id === "string" &&
61
+ typeof federal_congress_bill_action.bill_type_id === "string" &&
62
+ typeof federal_congress_bill_action.number === "number" &&
63
+ typeof federal_congress_bill_action.action_id === "string" &&
64
+ is_federal_congress_bill_action_type_id(federal_congress_bill_action.bill_action_type_id) &&
65
+ typeof federal_congress_bill_action.date === "string" &&
66
+ typeof federal_congress_bill_action.description === "string" &&
67
+ (Array.isArray(federal_congress_bill_action.federal_congress_committee_ids) && federal_congress_bill_action.federal_congress_committee_ids.every((federal_congress_committee_id : any) => typeof federal_congress_committee_id === "string")) &&
68
+ (Array.isArray(federal_congress_bill_action.federal_congress_vote_ids) && federal_congress_bill_action.federal_congress_vote_ids.every((federal_congress_vote_id : any) => typeof federal_congress_vote_id === "string"))
69
+ )
70
+ }
71
+
72
+ }
@@ -21,6 +21,7 @@ export class FederalCongressBillDocument {
21
21
  readonly bill_document_type_id : FederalCongressBillDocumentTypeID
22
22
  readonly format_id : string
23
23
  readonly publish_time? : string
24
+ readonly url : string
24
25
  readonly s3_id? : string
25
26
 
26
27
  constructor(federal_congress_bill_document : any) {
@@ -37,6 +38,7 @@ export class FederalCongressBillDocument {
37
38
  this.bill_document_type_id = federal_congress_bill_document.bill_document_type_id
38
39
  this.format_id = federal_congress_bill_document.format_id
39
40
  this.publish_time = federal_congress_bill_document.publish_time
41
+ this.url = federal_congress_bill_document.url
40
42
  this.s3_id = federal_congress_bill_document.s3_id
41
43
  }
42
44
 
@@ -53,6 +55,7 @@ export class FederalCongressBillDocument {
53
55
  is_federal_congress_bill_document_type_id(federal_congress_bill_document.bill_document_type_id) &&
54
56
  typeof federal_congress_bill_document.format_id === "string" &&
55
57
  (federal_congress_bill_document.publish_time === undefined || typeof federal_congress_bill_document.publish_time === "string") &&
58
+ typeof federal_congress_bill_document.url === "string" &&
56
59
  (federal_congress_bill_document.s3_id === undefined || typeof federal_congress_bill_document.s3_id === "string")
57
60
  )
58
61
  }
@@ -0,0 +1,35 @@
1
+ import { is_state_id, StateID } from "../State"
2
+
3
+ export class FederalCongressVote {
4
+ readonly federal_congress_vote_id : string
5
+ readonly federal_congress_id : number
6
+ readonly session_id : number
7
+ readonly chamber_id : string
8
+ readonly number : number
9
+ readonly date : string
10
+
11
+ constructor(federal_congress_vote : any) {
12
+ if (!FederalCongressVote.is(federal_congress_vote)) {
13
+ throw Error("Invalid input.")
14
+ }
15
+ this.federal_congress_vote_id = federal_congress_vote.federal_congress_vote_id
16
+ this.federal_congress_id = federal_congress_vote.federal_congress_id
17
+ this.session_id = federal_congress_vote.session_id
18
+ this.chamber_id = federal_congress_vote.chamber_id
19
+ this.number = federal_congress_vote.number
20
+ this.date = federal_congress_vote.date
21
+ }
22
+
23
+ static is(federal_congress_vote : any) : federal_congress_vote is FederalCongressVote {
24
+ return (
25
+ federal_congress_vote !== undefined &&
26
+ typeof federal_congress_vote.federal_congress_vote_id === "string" &&
27
+ typeof federal_congress_vote.federal_congress_id === "number" &&
28
+ typeof federal_congress_vote.session_id === "number" &&
29
+ typeof federal_congress_vote.chamber_id === "string" &&
30
+ typeof federal_congress_vote.number === "number" &&
31
+ typeof federal_congress_vote.date === "string"
32
+ )
33
+ }
34
+
35
+ }