triangle-types 1.0.3 → 1.0.5

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.
@@ -22,6 +22,17 @@ export declare class Voter {
22
22
  readonly address_mail_city: string;
23
23
  readonly address_mail_state_id: string;
24
24
  readonly address_mail_zip: string;
25
+ readonly occupation_group?: string;
26
+ readonly occupation_description?: string;
27
+ readonly phone_home?: string;
28
+ readonly phone_mobile?: string;
29
+ readonly ethnic_group?: string;
30
+ readonly ethnic_description?: string;
31
+ readonly religion_description?: string;
32
+ readonly party_description?: string;
33
+ readonly language?: string;
34
+ readonly education_level?: string;
35
+ readonly marital_status?: string;
25
36
  readonly [x: string]: any;
26
37
  constructor(voter: any);
27
38
  static is(voter: any): voter is Voter;
@@ -22,6 +22,17 @@ export class Voter {
22
22
  address_mail_city;
23
23
  address_mail_state_id;
24
24
  address_mail_zip;
25
+ occupation_group;
26
+ occupation_description;
27
+ phone_home;
28
+ phone_mobile;
29
+ ethnic_group;
30
+ ethnic_description;
31
+ religion_description;
32
+ party_description;
33
+ language;
34
+ education_level;
35
+ marital_status;
25
36
  constructor(voter) {
26
37
  if (!Voter.is(voter)) {
27
38
  throw Error("Invalid input.");
@@ -48,6 +59,17 @@ export class Voter {
48
59
  this.address_mail_city = voter.address_mail_city;
49
60
  this.address_mail_state_id = voter.address_mail_state_id;
50
61
  this.address_mail_zip = voter.address_mail_zip;
62
+ this.occupation_group = voter.occupation_group;
63
+ this.occupation_description = voter.occupation_description;
64
+ this.phone_home = voter.phone_home;
65
+ this.phone_mobile = voter.phone_mobile;
66
+ this.ethnic_group = voter.ethnic_group;
67
+ this.ethnic_description = voter.ethnic_description;
68
+ this.religion_description = voter.religion_description;
69
+ this.party_description = voter.party_description;
70
+ this.language = voter.language;
71
+ this.education_level = voter.education_level;
72
+ this.marital_status = voter.marital_status;
51
73
  }
52
74
  static is(voter) {
53
75
  return (voter !== undefined &&
@@ -72,7 +94,18 @@ export class Voter {
72
94
  (voter.address_mail_2 === undefined || typeof voter.address_mail_2 === "string") &&
73
95
  typeof voter.address_mail_city === "string" &&
74
96
  typeof voter.address_mail_state_id === "string" &&
75
- typeof voter.address_mail_zip === "string");
97
+ typeof voter.address_mail_zip === "string" &&
98
+ (voter.occupation_group === undefined || typeof voter.occupation_group === "string") &&
99
+ (voter.occupation_description === undefined || typeof voter.occupation_description === "string") &&
100
+ (voter.phone_home === undefined || typeof voter.phone_home === "string") &&
101
+ (voter.phone_mobile === undefined || typeof voter.phone_mobile === "string") &&
102
+ (voter.ethnic_group === undefined || typeof voter.ethnic_group === "string") &&
103
+ (voter.ethnic_description === undefined || typeof voter.ethnic_description === "string") &&
104
+ (voter.religion_description === undefined || typeof voter.religion_description === "string") &&
105
+ (voter.party_description === undefined || typeof voter.party_description === "string") &&
106
+ (voter.language === undefined || typeof voter.language === "string") &&
107
+ (voter.education_level === undefined || typeof voter.education_level === "string") &&
108
+ (voter.marital_status === undefined || typeof voter.marital_status === "string"));
76
109
  }
77
110
  }
78
111
  export class VoterAux extends Voter {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "triangle-types",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "scripts": {
@@ -23,6 +23,17 @@ export class Voter {
23
23
  readonly address_mail_city : string
24
24
  readonly address_mail_state_id : string
25
25
  readonly address_mail_zip : string
26
+ readonly occupation_group? : string
27
+ readonly occupation_description? : string
28
+ readonly phone_home? : string
29
+ readonly phone_mobile? : string
30
+ readonly ethnic_group? : string
31
+ readonly ethnic_description? : string
32
+ readonly religion_description? : string
33
+ readonly party_description? : string
34
+ readonly language? : string
35
+ readonly education_level? : string
36
+ readonly marital_status? : string
26
37
  readonly [x : string] : any
27
38
 
28
39
  constructor(voter : any) {
@@ -51,6 +62,17 @@ export class Voter {
51
62
  this.address_mail_city = voter.address_mail_city
52
63
  this.address_mail_state_id = voter.address_mail_state_id
53
64
  this.address_mail_zip = voter.address_mail_zip
65
+ this.occupation_group = voter.occupation_group
66
+ this.occupation_description = voter.occupation_description
67
+ this.phone_home = voter.phone_home
68
+ this.phone_mobile = voter.phone_mobile
69
+ this.ethnic_group = voter.ethnic_group
70
+ this.ethnic_description = voter.ethnic_description
71
+ this.religion_description = voter.religion_description
72
+ this.party_description = voter.party_description
73
+ this.language = voter.language
74
+ this.education_level = voter.education_level
75
+ this.marital_status = voter.marital_status
54
76
  }
55
77
 
56
78
  static is(voter : any) : voter is Voter {
@@ -77,7 +99,18 @@ export class Voter {
77
99
  (voter.address_mail_2 === undefined || typeof voter.address_mail_2 === "string") &&
78
100
  typeof voter.address_mail_city === "string" &&
79
101
  typeof voter.address_mail_state_id === "string" &&
80
- typeof voter.address_mail_zip === "string"
102
+ typeof voter.address_mail_zip === "string" &&
103
+ (voter.occupation_group === undefined || typeof voter.occupation_group === "string") &&
104
+ (voter.occupation_description === undefined || typeof voter.occupation_description === "string") &&
105
+ (voter.phone_home === undefined || typeof voter.phone_home === "string") &&
106
+ (voter.phone_mobile === undefined || typeof voter.phone_mobile === "string") &&
107
+ (voter.ethnic_group === undefined || typeof voter.ethnic_group === "string") &&
108
+ (voter.ethnic_description === undefined || typeof voter.ethnic_description === "string") &&
109
+ (voter.religion_description === undefined || typeof voter.religion_description === "string") &&
110
+ (voter.party_description === undefined || typeof voter.party_description === "string") &&
111
+ (voter.language === undefined || typeof voter.language === "string") &&
112
+ (voter.education_level === undefined || typeof voter.education_level === "string") &&
113
+ (voter.marital_status === undefined || typeof voter.marital_status === "string")
81
114
  )
82
115
  }
83
116
  }