title: Compare the properties of two PsCustomObjects
body: <p>I know that I can compare the <strong>values</strong>  of two PowerShell objects:</p>
  
  <pre><code>PS&gt; $A = [PsCustomObject]@{"A"=1; "B"=$True; "C"=$False}
  PS&gt; $B = [PsCustomObject]@{"A"=1; "B"=$False; "C"=$False}
  PS&gt; Compare-Object $A $B -Property A, B, C
  
  A  B     C SideIndicator
  -  -     - -------------
  1  False False =&gt;
  1  True  False &lt;=
  </code></pre>
  
  <p>However, I need to compare the existance the <strong>properties</strong> of two PowerShell objects.</p>
  
  <p>These objects would be considered the same:</p>
  
  <pre><code>PS&gt; $A = [PsCustomObject]@{"A"=1; "B"=$True; "C"=$False}
  PS&gt; $B = [PsCustomObject]@{"A"=1; "B"=$False; "C"=$True}
  PS&gt; Compare-Foo $A $B
  True
  </code></pre>
  
  <p>These objects would be considered NOT the same:</p>
  
  <pre><code>PS&gt; $A = [PsCustomObject]@{"A"=1; "C"=$False}
  PS&gt; $B = [PsCustomObject]@{"A"=1; "B"=$False; "C"=$False}
  PS&gt; Compare-Foo $A $B
  False
  </code></pre>
  
  <p>Is there a good way to do this?</p>