FeatureNotSupportedException
public sealed class FeatureNotSupportedException : OptrisSdkException
The hardware or the current configuration cannot do this.
Raised for a capability the camera genuinely lacks -- asking a simulated camera or an Xi80 for a process interface, for instance -- rather than for something that went wrong. Where a missing capability is routine, prefer the matching Try… method.
Example
// Either handle the exception... try { using ProcessInterface pif = camera.OpenProcessInterface(); } catch (FeatureNotSupportedException) { Console.WriteLine("this camera has no process interface"); } //...or ask without one. if (camera.TryOpenProcessInterface(out ProcessInterface? maybe)) { using (maybe) { Console.WriteLine(maybe.Identity.Kind); } }
FeatureNotSupportedException: constructors
public FeatureNotSupportedException(string message)
Create the exception.
message: What went wrong.
public FeatureNotSupportedException(string message, int status)
Create the exception with its native status.
message: What went wrong.status: The native status code.