Query Method (queryType)

SWI-Prolog SbsSW.SwiPlCs

Swi-cs-pl - A CSharp class library to connect .NET languages with SWI-Prolog Query Method (queryType)
SwiPlCs interfaceSbsSW.SwiPlCsPlQueryQuery(PlQuerySwitch)

Obtain status information on the Prolog system. The actual argument type depends on the information required. The parameter queryType describes what information is wanted.

Returning pointers and integers as a long is bad style. The signature of this function should be changed.

PlQuerySwitch
Declaration Syntax
C# Visual Basic Visual C++
public static long Query(
	PlQuerySwitch queryType
)
Public Shared Function Query ( _
	queryType As PlQuerySwitch _
) As Long
public:
static long long Query(
	PlQuerySwitch queryType
)
Parameters
queryType (PlQuerySwitch)
A PlQuerySwitch.
Return Value
A int depending on the given queryType
Examples

This sample shows how to get SWI-Prologs version number

CopyC#
public void Pl_query_version()
{
    long v = PlQuery.Query(PlQuerySwitch.Version);
    Assert.AreEqual(60301, v, "SWI-Prolog version number ");
}

Assembly: SwiPlCs (Module: SwiPlCs) Version: 1.1.60301.0 (1.1.60301.0)