title: How to create class library with interface(s) and/or methods used by Windows and/or PowerShell?
body: <p>I have a need to create a class library in C# which I'd like to include in a PowerShell module I'm writing. I'd like to consume the DLL in PowerShell by invoking a method much like you would as follows:</p>
  
  <pre><code>Add-Type -Path $($variableHash.RootPath + "\Deviceparserstandalone.dll")    
  [SkypeHelpers.CQTools.DeviceParser+Audio]::IsCertified($_.Caption)
  </code></pre>
  
  <p>The above is an example of PowerShell importing a DLL, then using the <code>IsCertified</code> method (i'm assuming it's a method).</p>
  
  <p>Here is what I'm looking for:</p>
  
  <ol>
  <li>Is there anything special I need to do other than create a new Visual Studio project with the .NET Core class library template, import the dependencies I need for my library, then compile the code to a DLL?</li>
  <li>How do I expose some methods to be used by the consuming application (in this case PowerShell) while keeping other methods 'private'? Would this be like using an interface to describe the methods available to the consuming application? If so, is this similar to creating an interface for an ASP.NET Core 2.x website?</li>
  </ol>
  
  <p>The goal is to write a class library that PowerShell can consume to create a toast notification for Windows 10. I realize there are public modules on PowerShell Gallery for this but I'm trying to understand how it's built from the ground up.</p>