The users often want to retrieve computed astrological values for further use. They can obviously Extract & Save the wanted values and retrieve them with a SELECT on the database, but they can also use a more direct way through the DBUS interface of Skylendar. DBUS is a well known interprocess communication system.
When run, Skylendar creates a org.skylendar-xxxx DBUS service, where xxxx stands for the process id. This service, in turn, creates the so-called "Vals" query object. This object proposes 11 methods for data retrieval.
int NbCharts
bool LockChart <int>
UnlockChart <int>
string GetChartName
int NbRings
string GetRingType <int>
bool IfObj <int> <string>
double GetVal <int> <string> <int>
double GetLong <int> <string>
int NbAspect
string GetAspect <int>
double GetMidPoint <string> <string>
int NbMPAspects
string GetMPAspect <int>
int SearchAspect <string> <string> <string> <int> <string>
double GetMidPoint <string> <string>
string GetEphemLine <int> <int> <int>
NbCharts
will return the number of present charts in Skylendar.
Before using a chart, you must lock it.
LockChart
will lock the chart with the given number. 0 is the first chart number. It will return FALSE if it can't lock the chart.
After having used a chart, don't forget to unlock it with
UnlockChart
.
GetChartName
will return the name of the locked chart.
NbRings
will return the number of active rings on the locked chart.
GetRingType
will return the short name of the type of the given ring.
IfObj
will tell you whether the given object (i.e. planet, cusp, star, etc...) is available or not.
GetVal
will return, for the given ring number, the decimal value of the nth value of the given object name. Longitude is 0, latitude 1, distance 2, speed 3, etc...
GetLong
will return the longitude of the given object for the given ring number.
NbAspect
will return the number of current aspects.
GetAspect
will return a coded string for the given aspect number. Number 0 for the first aspect, and string null when aspect not available.
GetMidPoint
will return the decimal value for the midpoint between the 2 given object short names.
NbMPAspects
will return the current number of aspects involving midpoints.
GetMPAspect
will return a coded string for the given aspect number. This aspect always involves a midpoint.
SearchAspect
will return the aspect id when first and third strings are objects short names, the second string is an aspect short name. The interger number is a possible aspect id after which SearchAspects will search for. If wanted, the fourth string is the object short name for the second member of a midpoint, having the second string as its fist member; the first string being the object the midpoint casts an aspect with. If one or more of those strings are "" (null), the query will be processed for ALL the objects corresponding to the given string. In addition, when the fourth string is a star "*", and the first one a number,
SearchAspect
will search for an aspect between a planet and an Arabic part whose number is given at the beginning. See examples below
GetMidPoint
will return the longitude value for the midpoint whose objects short names are string 1 and 2.
GetEphemLine
will return a string containing the longitude of the ten standard planets of the ephemeris for the given day, month, year.
This example will use the Net::DBus perl module.
Before using Net::DBus, you need to make some preliminary declarations in your test perl script:
#!/usr/bin/perl use Net::DBus; my $bus = Net::DBus->session(); my $service = $bus->get_service("org.skylendar.vals"); my $object = $service->get_object("/Vals");
print $object->NbChart();
2
print $object->LockChart(2);
true
Locks the second chart
print $object->GetChartName();
Standard Wheel Chart for Now
print $object->NbRings();
1
print $object->GetRingType(0);
Sgl
Single wheeel chart
print $object->IfObj(0, "Mar");
true
Mars is available on ring 0
print $object->GetVal(0, "Mar", 2);
0.535637
Mars-Earth distance
print $object->GetLong(0; "Mar");
336.636802
print $object->GetAspect(0);
Sun Con Mer 0.303790 (Good) Separating
Sun-Mercury conjunction. Actual orb: 0.3037, good accuracy, separating aspect
print $object->GetMidPoint("Moo", "Jup");
119.34563
print $object->SearchAspect("Sun", "Squ", "Moo", 0);
3
first square between the Sun and the Moon
print $object->SearchAspect("Sun", "Squ", "", 0);
3
first square between the Sun and any other planet
print $object->SearchAspect("Sun", "Tri", "", 2);
6
Third trine between the Sun and any other planet
print $object->SearchAspect("Sun", "", "", 0);
3
first aspect involving the Sun
print $object->SearchAspect("Sun", "", "MC ", 0, "Jup");
11
first aspect between the Sun and the midpoint MC/Jupiter
print $object->SearchAspect("4", "", "Sun", 0, "*");
17
first aspect between the arabic part of the anxiety and the Sun
print $object->GetMidPoint("Moo", "Jup");
47.09
Longitude of the midpoint Moon/Jupiter
print $object->UnlockChart();
Most modern script languages e.g. python, ruby, etc.. provide the users with the same possibilites. You can also use qdbusviewer with a simple graphical interface.