lib/Classes/Public/TMReference.ps1
class TMReference { [Object]$Id [String]$Name TMReference() {} TMReference([Int]$id, [String]$name) { $this.Id = $id $this.Name = $name } TMReference([String]$name, [Int]$id) { $this.Id = $id $this.Name = $name } TMReference([Object]$object) { $this.Id = $object.id $this.Name = $object.name } TMReference([Int]$id) { $this.Id = $id $this.Name = "" } TMReference([String]$name) { $this.Id = $null $this.Name = $name } [String]ToString() { return "{Id = $($this.Id), Name = $($this.Name)}" } } |