You can subscribe to this list here.
| 2010 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
(121) |
Dec
(58) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2011 |
Jan
(38) |
Feb
(36) |
Mar
(7) |
Apr
(2) |
May
(32) |
Jun
(24) |
Jul
(16) |
Aug
(21) |
Sep
(17) |
Oct
(62) |
Nov
(60) |
Dec
(70) |
| 2012 |
Jan
(54) |
Feb
(41) |
Mar
(21) |
Apr
(38) |
May
(76) |
Jun
(47) |
Jul
(25) |
Aug
(72) |
Sep
(29) |
Oct
(64) |
Nov
(93) |
Dec
(97) |
| 2013 |
Jan
(100) |
Feb
(168) |
Mar
(115) |
Apr
(59) |
May
(37) |
Jun
(32) |
Jul
(45) |
Aug
(42) |
Sep
(24) |
Oct
(73) |
Nov
(64) |
Dec
(4) |
| 2014 |
Jan
(14) |
Feb
(57) |
Mar
(58) |
Apr
(10) |
May
(18) |
Jun
(12) |
Jul
(7) |
Aug
(12) |
Sep
(15) |
Oct
(6) |
Nov
(32) |
Dec
(17) |
| 2015 |
Jan
(50) |
Feb
(5) |
Mar
(1) |
Apr
(26) |
May
(10) |
Jun
(3) |
Jul
(3) |
Aug
(2) |
Sep
(3) |
Oct
(18) |
Nov
(18) |
Dec
(8) |
| 2016 |
Jan
(33) |
Feb
(35) |
Mar
(50) |
Apr
(20) |
May
(25) |
Jun
(17) |
Jul
(8) |
Aug
(73) |
Sep
(64) |
Oct
(51) |
Nov
(20) |
Dec
(14) |
| 2017 |
Jan
(41) |
Feb
(57) |
Mar
(44) |
Apr
(136) |
May
(32) |
Jun
(39) |
Jul
(2) |
Aug
(12) |
Sep
(32) |
Oct
(103) |
Nov
(12) |
Dec
(4) |
| 2018 |
Jan
(9) |
Feb
(1) |
Mar
(60) |
Apr
(24) |
May
(15) |
Jun
(1) |
Jul
(2) |
Aug
(23) |
Sep
(15) |
Oct
(57) |
Nov
(21) |
Dec
(77) |
| 2019 |
Jan
(62) |
Feb
(99) |
Mar
(98) |
Apr
(49) |
May
(6) |
Jun
(3) |
Jul
(6) |
Aug
(18) |
Sep
(9) |
Oct
(15) |
Nov
(30) |
Dec
(6) |
| 2020 |
Jan
(14) |
Feb
(2) |
Mar
(22) |
Apr
(33) |
May
(47) |
Jun
(12) |
Jul
|
Aug
|
Sep
(4) |
Oct
(2) |
Nov
(5) |
Dec
(5) |
| 2021 |
Jan
(4) |
Feb
(101) |
Mar
(13) |
Apr
(32) |
May
(40) |
Jun
|
Jul
(3) |
Aug
|
Sep
|
Oct
(25) |
Nov
(12) |
Dec
|
| 2022 |
Jan
(154) |
Feb
(82) |
Mar
(63) |
Apr
(27) |
May
(26) |
Jun
(5) |
Jul
(12) |
Aug
(23) |
Sep
(17) |
Oct
(37) |
Nov
(13) |
Dec
(21) |
| 2023 |
Jan
(43) |
Feb
(43) |
Mar
(15) |
Apr
(8) |
May
(3) |
Jun
(25) |
Jul
(6) |
Aug
(38) |
Sep
(5) |
Oct
(20) |
Nov
(9) |
Dec
(28) |
| 2024 |
Jan
(15) |
Feb
(2) |
Mar
(12) |
Apr
(2) |
May
(8) |
Jun
(10) |
Jul
(10) |
Aug
(2) |
Sep
(3) |
Oct
(15) |
Nov
(6) |
Dec
(20) |
| 2025 |
Jan
|
Feb
(2) |
Mar
(6) |
Apr
(2) |
May
(2) |
Jun
|
Jul
|
Aug
(1) |
Sep
(1) |
Oct
(11) |
Nov
(2) |
Dec
|
|
From: <ma...@us...> - 2012-01-03 15:40:07
|
Revision: 630
http://openautomation.svn.sourceforge.net/openautomation/?rev=630&view=rev
Author: makki1
Date: 2012-01-03 15:39:57 +0000 (Tue, 03 Jan 2012)
Log Message:
-----------
WireGate-Plugins: SMTP revisited.. fix multiple recipients
Modified Paths:
--------------
wiregate/plugin/generic/SMTP-eMail.pl
wiregate/plugin/generic/Watchdog-SMTP-eMail
wiregate/plugin/generic/email_triggered_by_ga.pl
Modified: wiregate/plugin/generic/SMTP-eMail.pl
===================================================================
--- wiregate/plugin/generic/SMTP-eMail.pl 2012-01-03 12:28:27 UTC (rev 629)
+++ wiregate/plugin/generic/SMTP-eMail.pl 2012-01-03 15:39:57 UTC (rev 630)
@@ -2,7 +2,8 @@
# das macht nichts sinnvolles, sendet jede Stunde ein eMail,
# soll nur als Vorlage dienen
# - mit SSL (alte Version ohne SSL sieh SVN rev 622)
-# - benoetigt Paket libnet-smtp-ssl-perl
+# - benoetigt Paket libnet-smtp-ssl-perl libauthen-sasl-perl
+# (Updates->Pakete installieren oder apt-get install ..)
# Aufbau moeglichst so, dass man unterhalb der Definitionen nichts aendern muss!
@@ -17,7 +18,7 @@
my $Betreff = "eMail von $hostname";
my $text = "email-Body";
my $username = 'ab...@gm...'; #Anpassen! Username fuer SMTP-Server
-my $password = "meinpasswort"; #Anpassen! Passwort fuer SMTP-Server
+my $password = 'meinpasswort'; #Anpassen! Passwort fuer SMTP-Server
my $mailserver='mail.gmx.net:465'; # SMTP-Relay mit SSL: das muss natuerlich angepasst werden!
# oder z.B. smtp.gmail.com:465 fuer Gmail;
$plugin_info{$plugname.'_cycle'} = 3600;
@@ -33,7 +34,7 @@
$smtp->auth($username,$password) or return "SASL Auth failed $!;$@"; # try SASL
$smtp->status() < 5 or return "Auth failed: $!; $@ ". $smtp->status();
$smtp->mail($Absender) or return "Absender $Absender abgelehnt $!";
-$smtp->to($Empfaenger) or return "Empfaenger $Empfaenger abgelehnt $!";
+$smtp->to(split(',',$Empfaenger)) or return "Empfaenger $Empfaenger abgelehnt: $!";
$smtp->data() or return "Data failed $!";
$smtp->datasend("To: $Empfaenger\n") or return "Empfanger $Empfaenger (Header-To) abgelehnt $!";
$smtp->datasend("Subject: $Betreff\n") or return "Subject $Betreff abgelehnt $!";
Modified: wiregate/plugin/generic/Watchdog-SMTP-eMail
===================================================================
--- wiregate/plugin/generic/Watchdog-SMTP-eMail 2012-01-03 12:28:27 UTC (rev 629)
+++ wiregate/plugin/generic/Watchdog-SMTP-eMail 2012-01-03 15:39:57 UTC (rev 630)
@@ -1,7 +1,8 @@
# Demo-Plugin zum prüfen auf Plugin Timeout-Fehler
# und eMail-Versand
# - mit SSL (alte Version ohne SSL sieh SVN rev 622)
-# - benoetigt Paket libnet-smtp-ssl-perl
+# - benoetigt Paket libnet-smtp-ssl-perl libauthen-sasl-perl
+# (Updates->Pakete installieren oder apt-get install ..)
my $hostname = `hostname`;
@@ -13,7 +14,7 @@
my $Absender = 'WireGate <ab...@gm...>'; # unbedingt anpassen, die Absenderadresse sollte gültig sein um Probleme zu vermeiden
my $Betreff = "Plugin-Alarm von $hostname !";
my $username = 'ab...@gm...'; #Anpassen! Username fuer SMTP-Server
-my $password = "meinpasswort"; #Anpassen! Passwort fuer SMTP-Server
+my $password = 'meinpasswort'; #Anpassen! Passwort fuer SMTP-Server
my $mailserver='mail.gmx.net:465'; # SMTP-Relay mit SSL: das muss natuerlich angepasst werden!
# oder z.B. smtp.gmail.com:465 fuer Gmail;
$plugin_info{$plugname.'_cycle'} = 300;
@@ -38,7 +39,7 @@
$smtp->auth($username,$password) or return "SASL Auth failed $!;$@"; # try SASL
$smtp->status() < 5 or return "Auth failed: $! ". $smtp->status();
$smtp->mail($Absender) or return "Absender $Absender abgelehnt $!";
- $smtp->to($Empfaenger) or return "Empfaenger $Empfaenger abgelehnt $!";
+ $smtp->to(split(',',$Empfaenger)) or return "Empfaenger $Empfaenger abgelehnt $!";
$smtp->data() or return "Data failed $!";
$smtp->datasend("To: $Empfaenger\n") or return "Empfanger $Empfaenger (Header-To) abgelehnt $!";
$smtp->datasend("Subject: $Betreff\n") or return "Subject $Betreff abgelehnt $!";
Modified: wiregate/plugin/generic/email_triggered_by_ga.pl
===================================================================
--- wiregate/plugin/generic/email_triggered_by_ga.pl 2012-01-03 12:28:27 UTC (rev 629)
+++ wiregate/plugin/generic/email_triggered_by_ga.pl 2012-01-03 15:39:57 UTC (rev 630)
@@ -44,7 +44,7 @@
$smtp->auth($username,$password) or return "SASL Auth failed $!;$@"; # try SASL
$smtp->status() < 5 or return "Auth failed: $!; $@ ". $smtp->status();
$smtp->mail($Absender) or return "Absender $Absender abgelehnt $!";
- $smtp->to($email_adress) or return "Empfaenger $email_adress abgelehnt $!";
+ $smtp->to(split(',',$email_adress)) or return "Empfaenger $email_adress abgelehnt $!";
$smtp->data() or return "Data failed $!";
$smtp->datasend("To: $email_adress\n") or return "Empfanger $email_adress (Header-To) abgelehnt $!";
$smtp->datasend("Subject: $email_subject\n") or return "Subject $email_subject abgelehnt $!";
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <da...@us...> - 2012-01-03 12:28:34
|
Revision: 629
http://openautomation.svn.sourceforge.net/openautomation/?rev=629&view=rev
Author: daviid5
Date: 2012-01-03 12:28:27 +0000 (Tue, 03 Jan 2012)
Log Message:
-----------
Sends email, triggered by GA.
Added Paths:
-----------
wiregate/plugin/generic/email_triggered_by_ga.pl
Added: wiregate/plugin/generic/email_triggered_by_ga.pl
===================================================================
--- wiregate/plugin/generic/email_triggered_by_ga.pl (rev 0)
+++ wiregate/plugin/generic/email_triggered_by_ga.pl 2012-01-03 12:28:27 UTC (rev 629)
@@ -0,0 +1,60 @@
+#Plugin zum versenden von Emails beim Empfang eines definierten Werts auf einer definierten GA
+#Mehrere Mails an einer GA sind derzeit nicht m\xF6glich!
+# - benoetigt Paket libnet-smtp-ssl-perl
+# Aufbau moeglichst so, dass man unterhalb der Definitionen nichts aendern muss!
+
+my ($sec,$min,$hour,$day,$month,$yr19,@rest) = localtime(time);
+my $hostname = `hostname`;
+
+##################
+### DEFINITION ###
+##################
+
+my $Absender = 'WireGate <ex...@go...>'; # unbedingt anpassen, die Absenderadresse sollte g\xFCltig sein um Probleme zu vermeiden
+my $username = 'ex...@go...'; #Anpassen! Username fuer SMTP-Server
+my $password = 'yourPW'; #Anpassen! Passwort fuer SMTP-Server
+#my $mailserver='mail.gmx.net:465'; # SMTP-Relay mit SSL: das muss natuerlich angepasst werden!
+my $mailserver='smtp.gmail.com:465'; # SMTP-Relay mit SSL: das muss natuerlich angepasst werden!
+
+$plugin_info{$plugname.'_cycle'} = 3600;
+
+my @actionGA;
+push @actionGA, { name => "Alarmanlage", email_adress => 'em...@t-...', email_subject => "Test 1", email_text => "Alarmanlage hat um $hour:$min ausgel\xF6st.", trigger_ga => "12/1/0", value => 1 };
+push @actionGA, { name => "test", email_adress => 'em...@gm...', email_subject => "test2", email_text => "Test 2", trigger_ga => "1/1/1", value => 0 };
+push @actionGA, { name => "test", email_adress => 'em...@gm...', email_subject => "test3", email_text => "Test 3", trigger_ga => "1/1/2", value => 1 };
+
+#######################
+### ENDE DEFINITION ###
+#######################
+
+use Net::SMTP::SSL;
+use MIME::Base64;
+
+foreach my $element (@actionGA) {
+ my $email_adress = $element->{email_adress};
+ my $email_subject = $element->{email_subject};
+ my $email_text = $element->{email_text};
+ my $trigger_ga = $element->{trigger_ga};
+ my $value = $element->{value};
+
+ $plugin_subscribe{$trigger_ga}{$plugname} = 1;
+
+ if ($msg{'apci'} eq "A_GroupValue_Write" && $msg{'dst'} eq $trigger_ga && defined $msg{'value'} && $msg{'value'} == "$value" ) {
+ my $smtp = Net::SMTP::SSL->new($mailserver, Timeout => 10) or return "Fehler beim verbinden zu $mailserver $!; $@";
+ $smtp->auth($username,$password) or return "SASL Auth failed $!;$@"; # try SASL
+ $smtp->status() < 5 or return "Auth failed: $!; $@ ". $smtp->status();
+ $smtp->mail($Absender) or return "Absender $Absender abgelehnt $!";
+ $smtp->to($email_adress) or return "Empfaenger $email_adress abgelehnt $!";
+ $smtp->data() or return "Data failed $!";
+ $smtp->datasend("To: $email_adress\n") or return "Empfanger $email_adress (Header-To) abgelehnt $!";
+ $smtp->datasend("Subject: $email_subject\n") or return "Subject $email_subject abgelehnt $!";
+ $smtp->datasend("\n") or return "Data failed $!";
+ $smtp->datasend("$email_text\n") or return "Data failed $!";
+ $smtp->dataend() or return "Data failed $!";
+ $smtp->quit or return "Quit failed $!";
+
+ return; # keine Logausgabe
+ return "eMail von $Absender an $email_adress\ Betreff $email_subject gesendet: $email_text";
+
+ }
+}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2012-01-03 02:35:45
|
Revision: 628
http://openautomation.svn.sourceforge.net/openautomation/?rev=628&view=rev
Author: makki1
Date: 2012-01-03 02:35:39 +0000 (Tue, 03 Jan 2012)
Log Message:
-----------
WireGate-Plugin: Cleanup zombies in plugin_info
Added Paths:
-----------
wiregate/plugin/generic/PluginInfo_Cleanup.pl
Added: wiregate/plugin/generic/PluginInfo_Cleanup.pl
===================================================================
--- wiregate/plugin/generic/PluginInfo_Cleanup.pl (rev 0)
+++ wiregate/plugin/generic/PluginInfo_Cleanup.pl 2012-01-03 02:35:39 UTC (rev 628)
@@ -0,0 +1,44 @@
+# Plugin zum loeschen *ALLER* Eintraege in $plugin_info
+# fuer die kein Plugin mehr existiert.
+# Vorraussetzung: die Benutzung *MUSS* konsequent wie empfohlen mit
+# $plugin_info{$plugname.'_XYZ'} erfolgen.
+# Es werden alle Eintraege geloescht, die nicht mit einem (noch) vorhandenen
+# Plugin-Namen beginnen.
+# *** ERST MIT $delete=0 prüfen ! ***
+
+##################
+### DEFINITION ###
+##################
+
+my $delete = 0; # Auf 1 setzen zum loeschen, sonst nur Ausgabe ins Plugin-Log
+$plugin_info{$plugname.'_cycle'} = 86400;
+
+#######################
+### ENDE DEFINITION ###
+#######################
+
+my @plugin_basenames;
+my $ret;
+
+foreach (@plugins) {
+ next if ($_ =~ /\~$/ or -d $_); # ignore backup-files and subdirectories
+ push(@plugin_basenames, basename($_));
+}
+
+#Special Prefixes
+push(@plugin_basenames, 'Global_');
+
+while( my ($key, $value) = each(%plugin_info) ) {
+ my (@prefix) = split '_',$key;
+ if (! grep (/^\Q$prefix[0]\E.*/, @plugin_basenames)) {
+ if ($delete) {
+ delete $plugin_info{$key};
+ $ret .= " *DELETED*: " . $key;
+ } else {
+ $ret .= " *WOULD delete*: " . $key;
+ }
+ }
+}
+
+return $ret;
+
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <da...@us...> - 2012-01-02 23:14:10
|
Revision: 627
http://openautomation.svn.sourceforge.net/openautomation/?rev=627&view=rev
Author: daviid5
Date: 2012-01-02 23:14:04 +0000 (Mon, 02 Jan 2012)
Log Message:
-----------
First Beta-Version of simple scene plugin
Added Paths:
-----------
wiregate/plugin/generic/Szenen.pl
Added: wiregate/plugin/generic/Szenen.pl
===================================================================
--- wiregate/plugin/generic/Szenen.pl (rev 0)
+++ wiregate/plugin/generic/Szenen.pl 2012-01-02 23:14:04 UTC (rev 627)
@@ -0,0 +1,28 @@
+# Beta-Version
+#
+#
+# Plugin f\xFCr Szenen
+# ga1 = GA
+# wert = Wert der auf die GA gesendet werden soll (DPT ist durch import der GAs aus der ETS festzulegen
+# Aufbau moeglichst so, dass man unterhalb der Definitionen nichts aendern muss!
+
+
+my $trigger_ga = '8/2/0'; # triggert die Szene mit einer 1 (DPT 1)
+$plugin_subscribe{$trigger_ga}{$plugname} = 1;
+
+my @GAs;
+push @GAs, { name => "Wohnzimmer TV", ga1 => "1/1/35", wert => 1 };
+push @GAs, { name => "Wohnzimmer Kamin", ga1 => "1/1/11", wert => 0 };
+push @GAs, { name => "Wohnzimmer T\xFCr", ga1 => "1/1/2", wert => 0 };
+push @GAs, { name => "Wohnzimmer Mitte", ga1 => "1/1/38", wert => 0 };
+push @GAs, { name => "Wohnzimmer Fenster", ga1 => "1/1/34" , wert => 0 };
+
+#push @GAs, { name => "Wohnzimmer TV dimmen", ga1 => "1/1/37" , wert => 50};
+
+
+if ($msg{'apci'} eq "A_GroupValue_Write" && $msg{'dst'} eq $trigger_ga && defined $msg{'value'} && $msg{'value'} == "1" ) {
+
+ foreach my $element (@GAs) {
+ knx_write($element->{ga1}, $element->{wert}, 1.001);
+ }
+}
\ No newline at end of file
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2012-01-02 22:00:37
|
Revision: 626
http://openautomation.svn.sourceforge.net/openautomation/?rev=626&view=rev
Author: mayerch
Date: 2012-01-02 22:00:31 +0000 (Mon, 02 Jan 2012)
Log Message:
-----------
Bug fix for #3468526: Initial read is repeated after COMET Timeout
Modified Paths:
--------------
CometVisu/trunk/visu/lib/cometvisu-client.js
Modified: CometVisu/trunk/visu/lib/cometvisu-client.js
===================================================================
--- CometVisu/trunk/visu/lib/cometvisu-client.js 2012-01-02 12:08:29 UTC (rev 625)
+++ CometVisu/trunk/visu/lib/cometvisu-client.js 2012-01-02 22:00:31 UTC (rev 626)
@@ -32,6 +32,7 @@
this.xhr = false; // the ongoing AJAX request
this.watchdogTimer = 5; // in Seconds - the alive check intervall of the watchdog
this.maxConnectionAge = 60; // in Seconds - restart if last read is older
+ this.lastIndex = 0; // index returned by the last request
/**
* This function gets called once the communication is established and session information is available
@@ -54,7 +55,7 @@
*/
this.handleRead = function( json )
{
- if( !json )
+ if( !json && !this.doRestart )
{
if( this.running )
{ // retry initial request
@@ -64,13 +65,16 @@
return;
}
- var lastIndex = json.i;
- var data = json.d;
- this.update( data );
+ if( !this.doRestart )
+ {
+ this.lastIndex = json.i;
+ var data = json.d;
+ this.update( data );
+ }
if( this.running )
{ // keep the requests going
- this.xhr = $.ajax( {url:this.urlPrefix + 'r',dataType: 'json',context:this,data:this.buildRequest()+'&i='+lastIndex, success:this.handleRead ,error:this.handleError/*,complete:this.handleComplete*/ } );
+ this.xhr = $.ajax( {url:this.urlPrefix + 'r',dataType: 'json',context:this,data:this.buildRequest()+'&i='+this.lastIndex, success:this.handleRead ,error:this.handleError/*,complete:this.handleComplete*/ } );
watchdog.ping();
}
};
@@ -168,8 +172,8 @@
{
this.doRestart = true;
if( this.xhr.abort ) this.xhr.abort();
+ this.handleRead(); // restart
this.doRestart = false;
- this.handleRead(); // restart
}
/**
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2012-01-02 12:08:35
|
Revision: 625
http://openautomation.svn.sourceforge.net/openautomation/?rev=625&view=rev
Author: makki1
Date: 2012-01-02 12:08:29 +0000 (Mon, 02 Jan 2012)
Log Message:
-----------
WireGate-Plugins: SMTP with SSL-only to simplify plugin as any provider supports SSL anyway
Modified Paths:
--------------
wiregate/plugin/generic/SMTP-eMail.pl
wiregate/plugin/generic/Watchdog-SMTP-eMail
Modified: wiregate/plugin/generic/SMTP-eMail.pl
===================================================================
--- wiregate/plugin/generic/SMTP-eMail.pl 2012-01-01 21:57:46 UTC (rev 624)
+++ wiregate/plugin/generic/SMTP-eMail.pl 2012-01-02 12:08:29 UTC (rev 625)
@@ -1,6 +1,8 @@
# Demo-Plugin zum eMail-Versand - einfache Version mit Text-only
# das macht nichts sinnvolles, sendet jede Stunde ein eMail,
# soll nur als Vorlage dienen
+# - mit SSL (alte Version ohne SSL sieh SVN rev 622)
+# - benoetigt Paket libnet-smtp-ssl-perl
# Aufbau moeglichst so, dass man unterhalb der Definitionen nichts aendern muss!
@@ -16,29 +18,20 @@
my $text = "email-Body";
my $username = 'ab...@gm...'; #Anpassen! Username fuer SMTP-Server
my $password = "meinpasswort"; #Anpassen! Passwort fuer SMTP-Server
-my $mailserver='mail.gmx.net'; # SMTP-Relay: das muss natuerlich angepasst werden!
+my $mailserver='mail.gmx.net:465'; # SMTP-Relay mit SSL: das muss natuerlich angepasst werden!
+# oder z.B. smtp.gmail.com:465 fuer Gmail;
$plugin_info{$plugname.'_cycle'} = 3600;
#######################
### ENDE DEFINITION ###
#######################
-use Net::SMTP;
+use Net::SMTP::SSL;
use MIME::Base64;
-my $smtp = Net::SMTP->new($mailserver, Timeout => 20, Debug =>1) or return "Fehler beim verbinden zu $mailserver $!; $@";
-$smtp->auth($username,$password);
-$smtp->status() < 5
-or do {
- #Die smtp->auth Methode schlaegt fehl, also dann so
- $smtp->datasend("AUTH LOGIN\n") or return 'auth login problem $!';
- $smtp->response();
- $smtp->datasend(encode_base64( $username ) ) or return "username $username cannot be encoded or wrong $!";
- $smtp->response();
- $smtp->datasend(encode_base64( $password ) ) or return "password $password cannot be encoded or wrong $!";
- $smtp->response();
-};
-$smtp->status() < 5 or return "Auth failed: $! ". $smtp->status();
+my $smtp = Net::SMTP::SSL->new($mailserver, Timeout => 10) or return "Fehler beim verbinden zu $mailserver $!; $@";
+$smtp->auth($username,$password) or return "SASL Auth failed $!;$@"; # try SASL
+$smtp->status() < 5 or return "Auth failed: $!; $@ ". $smtp->status();
$smtp->mail($Absender) or return "Absender $Absender abgelehnt $!";
$smtp->to($Empfaenger) or return "Empfaenger $Empfaenger abgelehnt $!";
$smtp->data() or return "Data failed $!";
Modified: wiregate/plugin/generic/Watchdog-SMTP-eMail
===================================================================
--- wiregate/plugin/generic/Watchdog-SMTP-eMail 2012-01-01 21:57:46 UTC (rev 624)
+++ wiregate/plugin/generic/Watchdog-SMTP-eMail 2012-01-02 12:08:29 UTC (rev 625)
@@ -1,5 +1,7 @@
# Demo-Plugin zum prüfen auf Plugin Timeout-Fehler
-# und eMail-Versand
+# und eMail-Versand
+# - mit SSL (alte Version ohne SSL sieh SVN rev 622)
+# - benoetigt Paket libnet-smtp-ssl-perl
my $hostname = `hostname`;
@@ -12,16 +14,16 @@
my $Betreff = "Plugin-Alarm von $hostname !";
my $username = 'ab...@gm...'; #Anpassen! Username fuer SMTP-Server
my $password = "meinpasswort"; #Anpassen! Passwort fuer SMTP-Server
-my $mailserver='mail.gmx.net'; # SMTP-Relay: das muss natuerlich angepasst werden!
+my $mailserver='mail.gmx.net:465'; # SMTP-Relay mit SSL: das muss natuerlich angepasst werden!
+# oder z.B. smtp.gmail.com:465 fuer Gmail;
$plugin_info{$plugname.'_cycle'} = 300;
#######################
### ENDE DEFINITION ###
#######################
-use Net::SMTP;
+use Net::SMTP::SSL;
use MIME::Base64;
-# FIXME: require Authen/SASL ?
my ($ret,$err);
@@ -32,18 +34,8 @@
# Alert
if (!$plugin_info{$plugname2.'_timeout_alarm'}) {
# sende Warn-eMail
- my $smtp = Net::SMTP->new($mailserver, Timeout => 20, Debug =>1) or return "Fehler beim verbinden zu $mailserver $!; $@";
- $smtp->auth($username,$password);
- $smtp->status() < 5
- or do {
- #Die smtp->auth Methode schlaegt fehl, also dann so
- $smtp->datasend("AUTH LOGIN\n") or return 'auth login problem $!';
- $smtp->response();
- $smtp->datasend(encode_base64( $username ) ) or return "username $username cannot be encoded or wrong $!";
- $smtp->response();
- $smtp->datasend(encode_base64( $password ) ) or return "password $password cannot be encoded or wrong $!";
- $smtp->response();
- };
+ my $smtp = Net::SMTP::SSL->new($mailserver, Timeout => 10) or return "Fehler beim verbinden zu $mailserver $!; $@";
+ $smtp->auth($username,$password) or return "SASL Auth failed $!;$@"; # try SASL
$smtp->status() < 5 or return "Auth failed: $! ". $smtp->status();
$smtp->mail($Absender) or return "Absender $Absender abgelehnt $!";
$smtp->to($Empfaenger) or return "Empfaenger $Empfaenger abgelehnt $!";
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tho...@us...> - 2012-01-01 21:57:53
|
Revision: 624
http://openautomation.svn.sourceforge.net/openautomation/?rev=624&view=rev
Author: thomas_s
Date: 2012-01-01 21:57:46 +0000 (Sun, 01 Jan 2012)
Log Message:
-----------
added 'using std::string'
replaced 'using namespace' by 'using <class>'
Modified Paths:
--------------
xPLHAL/branches/thomas_s_dev/src/devicemanager.cpp
xPLHAL/branches/thomas_s_dev/src/devicemanager.h
xPLHAL/branches/thomas_s_dev/src/globals.h
xPLHAL/branches/thomas_s_dev/src/xhcp.cpp
xPLHAL/branches/thomas_s_dev/src/xhcp.h
xPLHAL/branches/thomas_s_dev/src/xhcpthread.cpp
xPLHAL/branches/thomas_s_dev/src/xhcpthread.h
xPLHAL/branches/thomas_s_dev/src/xplcache.cpp
xPLHAL/branches/thomas_s_dev/src/xplhandler.cpp
xPLHAL/branches/thomas_s_dev/src/xplmessage.cpp
Modified: xPLHAL/branches/thomas_s_dev/src/devicemanager.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/devicemanager.cpp 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/devicemanager.cpp 2012-01-01 21:57:46 UTC (rev 624)
@@ -19,23 +19,31 @@
#include <boost/regex.hpp>
#include <cstdio>
-using namespace boost::algorithm;
+using boost::algorithm::to_lower;
+using boost::algorithm::split;
+using boost::algorithm::is_any_of;
+using boost::algorithm::token_compress_on;
#include "log.h"
#include "devicemanager.h"
#include "i_xplcache.h"
-using namespace boost::posix_time;
+using boost::posix_time::ptime;
+using boost::posix_time::second_clock;
+using boost::posix_time::minutes;
-deviceManagerClass::deviceManagerClass(IxPLCacheClass* xplcache)
+using std::string;
+using std::vector;
+
+DeviceManager::DeviceManager(IxPLCacheClass* xplcache)
:m_xPLCache(xplcache)
{
}
-void deviceManagerClass::add( const xPLDevice& device )
+void DeviceManager::add( const xPLDevice& device )
{
- writeLog("deviceManagerClass::add(" + device.VDI + ")", logLevel::debug);
+ writeLog("DeviceManager::add(" + device.VDI + ")", logLevel::debug);
if (contains( device.VDI )) {
mDeviceMap[device.VDI] = device;
} else {
@@ -44,9 +52,9 @@
}
}
-bool deviceManagerClass::remove( const std::string& deviceTag )
+bool DeviceManager::remove( const string& deviceTag )
{
- writeLog( "deviceManagerClass::remove("+deviceTag+")", logLevel::debug );
+ writeLog( "DeviceManager::remove("+deviceTag+")", logLevel::debug );
auto device = mDeviceMap.find(deviceTag);
if (device != mDeviceMap.end()) {
mDeviceMap.erase(device);
@@ -55,11 +63,11 @@
return false;
}
-bool deviceManagerClass::removeConfig( const std::string& deviceTag ) const
+bool DeviceManager::removeConfig( const string& deviceTag ) const
{
- writeLog( "deviceManagerClass::remove("+deviceTag+")", logLevel::debug );
+ writeLog( "DeviceManager::remove("+deviceTag+")", logLevel::debug );
if( containsConfig( deviceTag ) ) {
- std::vector<std::string> list = m_xPLCache->childNodes( "config." + deviceTag );
+ vector<string> list = m_xPLCache->childNodes( "config." + deviceTag );
for (auto listitem : list) {
m_xPLCache->deleteEntry(listitem);
}
@@ -68,7 +76,7 @@
return false;
}
-xPLDevice deviceManagerClass::getDevice( const std::string& deviceTag ) const
+xPLDevice DeviceManager::getDevice( const string& deviceTag ) const
{
xPLDevice retval;
auto device = mDeviceMap.find(deviceTag);
@@ -78,20 +86,20 @@
return retval;
}
-std::vector<std::string> deviceManagerClass::getAllDeviceNames() const
+vector<string> DeviceManager::getAllDeviceNames() const
{
- std::vector<std::string> retval;
+ vector<string> retval;
retval.reserve(mDeviceMap.size());
for (auto node : mDeviceMap) {
retval.push_back(node.first);
- writeLog( "deviceManagerClass::getAllDeviceNames() = "+ node.first, logLevel::debug );
+ writeLog( "DeviceManager::getAllDeviceNames() = "+ node.first, logLevel::debug );
}
return retval;
}
-void deviceManagerClass::processXplMessage( const xPLMessagePtr message )
+void DeviceManager::processXplMessage( const xPLMessagePtr message )
{
- std::string schema = message->msgClass + std::string(".") + message->msgType;
+ string schema = message->msgClass + string(".") + message->msgType;
if( message->type != xPL_MESSAGE_COMMAND )
{
if( "config.list" == schema )
@@ -121,11 +129,11 @@
}
}
-void deviceManagerClass::processConfigList( const xPLMessagePtr message )
+void DeviceManager::processConfigList( const xPLMessagePtr message )
{
- std::string source = message->getSourceVDI();
+ string source = message->getSourceVDI();
xPLDevice device = getDevice( source );
- writeLog( "deviceManagerClass::processConfigList("+source+") - found ["+device.VDI+"]", logLevel::debug );
+ writeLog( "DeviceManager::processConfigList("+source+") - found ["+device.VDI+"]", logLevel::debug );
if( "" == device.VDI ) {
// A config list turned up that we haven't asked for...
// create a new device...
@@ -146,10 +154,10 @@
}
for( auto entry : message->namedValues) {
- std::string newtag = "config." + source + ".options.";
- std::string value = entry.first;
+ string newtag = "config." + source + ".options.";
+ string value = entry.first;
to_lower(value);
- std::string key = entry.second;
+ string key = entry.second;
to_lower(key);
boost::regex re( "([a-z0-9]{1,16})\\[(\\d{1,3})\\]" );
boost::smatch matches;
@@ -180,7 +188,7 @@
}
}
-ptime deviceManagerClass::calculateExpireTime(const std::string& string_interval, int *pInterval)
+ptime DeviceManager::calculateExpireTime(const string& string_interval, int *pInterval)
{
int interval = string_interval.empty() ? atoi(string_interval.c_str()) : 5; // default to 5 minutes
if (pInterval) {
@@ -189,17 +197,17 @@
return calculateExpireTime(interval);
}
-ptime deviceManagerClass::calculateExpireTime(int interval)
+ptime DeviceManager::calculateExpireTime(int interval)
{
return second_clock::local_time() + minutes( 2* interval + 1 );
}
-void deviceManagerClass::processConfigHeartBeat( const xPLMessagePtr message )
+void DeviceManager::processConfigHeartBeat( const xPLMessagePtr message )
{
- std::string source = message->getSourceVDI();
+ string source = message->getSourceVDI();
xPLDevice device = getDevice( source );
- writeLog( "deviceManagerClass::processConfigHeartBeat("+source+") - found ["+device.VDI+"]", logLevel::debug );
+ writeLog( "DeviceManager::processConfigHeartBeat("+source+") - found ["+device.VDI+"]", logLevel::debug );
if( device.VDI.empty() ) {
// this handles a new application that identifies itself with a hbeat straight away.
// it must either be storing it's config locally, can't be configured, or is configured somewhere else.
@@ -235,11 +243,11 @@
}
}
-void deviceManagerClass::processCurrentConfig( const xPLMessagePtr message )
+void DeviceManager::processCurrentConfig( const xPLMessagePtr message )
{
- std::string source = message->getSourceVDI();
+ string source = message->getSourceVDI();
xPLDevice device = getDevice( source );
- writeLog( "deviceManagerClass::processCurrentConfig("+source+") - found ["+device.VDI+"]", logLevel::debug );
+ writeLog( "DeviceManager::processCurrentConfig("+source+") - found ["+device.VDI+"]", logLevel::debug );
if( "" == device.VDI ) {
// A current config turned up for a device that we don't know...
// Processing the current config doesn't make sense as long as we don't know the config list
@@ -251,14 +259,14 @@
m_xPLCache->updateEntry( "config." + source + ".current", "true", false );
}
- std::string multiKey;
+ string multiKey;
int multiCount = 0;
for( auto entry : message->namedValues) {
- std::string value = entry.first;
+ string value = entry.first;
to_lower(value);
- std::string key = entry.second;
+ string key = entry.second;
to_lower(key);
- std::string count = m_xPLCache->objectValue( "config." + source + ".options." + key + ".count" );
+ string count = m_xPLCache->objectValue( "config." + source + ".options." + key + ".count" );
if( "" != count ) {
if( multiKey == key ) {
multiCount++;
@@ -274,14 +282,14 @@
}
}
-void deviceManagerClass::processHeartbeat( xPLMessagePtr message )
+void DeviceManager::processHeartbeat( xPLMessagePtr message )
{
- std::string source = message->getSourceVDI();
+ string source = message->getSourceVDI();
xPLDevice device = getDevice( source );
int interval = 5;
ptime expires = calculateExpireTime(message->getNamedValue("interval"), &interval);
- writeLog( "deviceManagerClass::processHeartbeat("+source+") - found ["+device.VDI+"]", logLevel::debug );
+ writeLog( "DeviceManager::processHeartbeat("+source+") - found ["+device.VDI+"]", logLevel::debug );
if( "" == device.VDI ) {
// this handles a new application that identifies itself with a hbeat straight away.
@@ -316,24 +324,24 @@
}
}
-void deviceManagerClass::processRemove( xPLMessagePtr message )
+void DeviceManager::processRemove( xPLMessagePtr message )
{
- std::string source = message->getSourceVDI();
+ string source = message->getSourceVDI();
remove( source );
removeConfig( source );
}
-void deviceManagerClass::sendConfigResponse( const std::string& source, const bool removeOldValue )
+void DeviceManager::sendConfigResponse( const string& source, const bool removeOldValue )
{
- writeLog( "deviceManagerClass::sendConfigResponse("+source+", "+(removeOldValue?"true":"false")+")", logLevel::debug );
+ writeLog( "DeviceManager::sendConfigResponse("+source+", "+(removeOldValue?"true":"false")+")", logLevel::debug );
boost::regex re( "config\\." + source + "\\.current\\.([a-z0-9]{1,16})(?:\\{([0-9]{1,3})\\})?" );
- std::vector<std::string> entries = m_xPLCache->filterByRegEx( re );
+ vector<string> entries = m_xPLCache->filterByRegEx( re );
xPLMessage::namedValueList list;
for( auto entry : entries) {
boost::smatch matches;
boost::regex_match( entry, matches, re );
- writeLog( "deviceManagerClass::sendConfigResponse: ["+entry+"] -> ["+matches[1]+"]("+matches[2]+")",logLevel::debug );
+ writeLog( "DeviceManager::sendConfigResponse: ["+entry+"] -> ["+matches[1]+"]("+matches[2]+")",logLevel::debug );
if( matches.size() > 1 ) {
list.push_back( std::make_pair( matches[1], m_xPLCache->objectValue( entry ) ) );
}
@@ -356,24 +364,24 @@
}
}
-bool deviceManagerClass::storeNewConfig( const std::string& source, const std::string& config )
+bool DeviceManager::storeNewConfig( const string& source, const string& config )
{
- writeLog( "deviceManagerClass::storeNewConfig("+source+", "+config+")", logLevel::debug );
+ writeLog( "DeviceManager::storeNewConfig("+source+", "+config+")", logLevel::debug );
auto device = mDeviceMap.find(source);
if (device == mDeviceMap.end()) {
return false;
}
- std::vector<std::string> list;
+ vector<string> list;
split( list, config, is_any_of("\r\n"), token_compress_on );
- std::string multiKey;
+ string multiKey;
int multiCount = 0;
for( auto listitem : list) {
- std::vector<std::string> tags;
+ vector<string> tags;
split( tags, listitem, is_any_of("=") );
to_lower( tags[0] );
to_lower( tags[1] );
- std::string count = m_xPLCache->objectValue( "config." + source + ".options." + tags[0] + ".count" );
+ string count = m_xPLCache->objectValue( "config." + source + ".options." + tags[0] + ".count" );
if( "" != count ) {
if( multiKey != tags[0] ) {
multiKey = tags[0];
@@ -394,12 +402,12 @@
return true;
}
-bool deviceManagerClass::contains( const std::string& deviceTag ) const
+bool DeviceManager::contains( const string& deviceTag ) const
{
return mDeviceMap.find(deviceTag) != mDeviceMap.end();
}
-bool deviceManagerClass::containsConfig( const std::string& configTag ) const
+bool DeviceManager::containsConfig( const string& configTag ) const
{
return m_xPLCache->childNodes( "config." + configTag ).size() > 0;
}
Modified: xPLHAL/branches/thomas_s_dev/src/devicemanager.h
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/devicemanager.h 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/devicemanager.h 2012-01-01 21:57:46 UTC (rev 624)
@@ -27,10 +27,10 @@
#include "globals.h"
#include "xpldevice.h"
-class deviceManagerClass
+class DeviceManager
{
public:
- deviceManagerClass(IxPLCacheClass* xplcache);
+ DeviceManager(IxPLCacheClass* xplcache);
/** \brief Looks if the device deviceTag is known. */
bool contains( const std::string& deviceTag ) const;
Modified: xPLHAL/branches/thomas_s_dev/src/globals.h
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/globals.h 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/globals.h 2012-01-01 21:57:46 UTC (rev 624)
@@ -28,9 +28,6 @@
class xPLCacheClass;
extern xPLCacheClass *xPLCache;
-class deviceManagerClass;
-extern deviceManagerClass *deviceManager;
-
class xPLHandler;
extern xPLHandler *xPL;
Modified: xPLHAL/branches/thomas_s_dev/src/xhcp.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xhcp.cpp 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/xhcp.cpp 2012-01-01 21:57:46 UTC (rev 624)
@@ -23,9 +23,10 @@
using boost::asio::ip::tcp;
-XHCPServer::XHCPServer(boost::asio::io_service& io)
+XHCPServer::XHCPServer(boost::asio::io_service& io, DeviceManager* dm)
:m_io(io)
,m_acceptor(io, tcp::endpoint(tcp::v4(), 3865))
+,m_dm(dm)
{
startAccept();
}
@@ -45,6 +46,6 @@
void XHCPServer::handleAccept(socket_ptr sockPtr)
{
startAccept();
- XHCPThread* foo = new XHCPThread( sockPtr );
+ XHCPThread* foo = new XHCPThread(sockPtr, m_dm);
}
Modified: xPLHAL/branches/thomas_s_dev/src/xhcp.h
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xhcp.h 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/xhcp.h 2012-01-01 21:57:46 UTC (rev 624)
@@ -33,7 +33,7 @@
//boost::thread m_thread;
public:
- XHCPServer(boost::asio::io_service& io);
+ XHCPServer(boost::asio::io_service& io, DeviceManager* dm);
~XHCPServer();
protected:
@@ -46,4 +46,5 @@
private:
boost::asio::io_service& m_io;
boost::asio::ip::tcp::tcp::acceptor m_acceptor;
+ DeviceManager* m_dm;
};
Modified: xPLHAL/branches/thomas_s_dev/src/xhcpthread.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xhcpthread.cpp 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/xhcpthread.cpp 2012-01-01 21:57:46 UTC (rev 624)
@@ -27,14 +27,27 @@
#include "xhcpthread.h"
-using namespace boost::algorithm;
+using boost::algorithm::to_lower;
+using boost::algorithm::split;
+using boost::algorithm::is_any_of;
+using boost::algorithm::token_compress_on;
+using boost::algorithm::to_lower_copy;
+
using boost::asio::ip::tcp;
+using std::string;
+using std::vector;
-XHCPThread::XHCPThread( socket_ptr socket )
- : m_stoprequested(false), tab( "\t" ), newLine( "\r\n" ), endMultiLine( ".\r\n" ),
- sock( socket ), quit( false ),
- inMultilineRequest( false ), multilineRequestHandler( 0 ),
- m_thread(boost::bind(&XHCPThread::run, this))
+XHCPThread::XHCPThread( socket_ptr socket, DeviceManager* dm )
+ : m_stoprequested(false)
+ , tab( "\t" )
+ , newLine( "\r\n" )
+ , endMultiLine( ".\r\n" )
+ , sock( socket )
+ , quit( false )
+ , inMultilineRequest( false )
+ , multilineRequestHandler( 0 )
+ , m_thread(boost::bind(&XHCPThread::run, this))
+ , m_deviceManager(dm)
{
}
@@ -50,7 +63,7 @@
* Little helper that returns true if str doesn't end with end
* FIXME: use Boost functionality instead...
*/
-bool endDifferent( std::string str, std::string end )
+bool endDifferent( string str, string end )
{
size_t str_l = str.size();
size_t end_l = end.size();
@@ -60,7 +73,7 @@
void XHCPThread::run()
{
- writeLog( std::string("XHCPThread::run() [")+ lexical_cast<std::string>(sock.use_count()) +"]", logLevel::debug );
+ writeLog( string("XHCPThread::run() [")+ lexical_cast<string>(sock.use_count()) +"]", logLevel::debug );
// initialize here to make sure it's done in advance
// commands[ "ADDEVENT" ] = &XHCPThread::;
@@ -109,14 +122,14 @@
boost::asio::streambuf sb;
boost::system::error_code error;
- std::string greeting( "200 CHRISM-XPLHAL.SERVER1 Version 0.0 alpha XHCP 1.5 ready\r\n" );
+ string greeting( "200 CHRISM-XPLHAL.SERVER1 Version 0.0 alpha XHCP 1.5 ready\r\n" );
boost::asio::write(*sock, boost::asio::buffer(greeting));
while (!quit) {
// const int TimeoutInCommand = 5 * 1000; // during transmission of an command
// const int TimeoutExCommand = 300 * 1000; // between different commands
- std::string data;
+ string data;
while ( (!inMultilineRequest && endDifferent(data, "\r\n") )
|| ( inMultilineRequest && endDifferent(data, "\r\n.\r\n") ) ) {
@@ -124,12 +137,12 @@
std::size_t n = boost::asio::read_until(*sock, sb, '\n');
boost::asio::streambuf::const_buffers_type bufs = sb.data();
- std::string newData(
+ string newData(
boost::asio::buffers_begin(bufs),
boost::asio::buffers_begin(bufs) + n);
sb.consume(n);
/*
- std::string newData;
+ string newData;
size_t length = sock->read_some(boost::asio::buffer(newData), error);
if (error == boost::asio::error::eof)
@@ -148,7 +161,7 @@
}
writeLog( "Request: [" + data + "]", logLevel::debug );
- std::string result = (this->*multilineRequestHandler)( data );
+ string result = (this->*multilineRequestHandler)( data );
writeLog( "Result:\n[\n" + result + "]", logLevel::debug );
//socket.write( result );
boost::asio::write(*sock, boost::asio::buffer(result));
@@ -158,11 +171,11 @@
size_t spacePos = data.find( ' ' );
//boost::algorithm::to_upper( data.substr( 0, spacePos ) );
- writeLog( "data.substr( 0, spacePos ) [" + data.substr( 0, spacePos ) + "]["+(std::string::npos == spacePos ? "" : data.substr( spacePos+1 ))+"]", logLevel::error );
- writeLog( "npos: "+lexical_cast<std::string>(std::string::npos) + " - spacePos: + "+lexical_cast<std::string>(spacePos), logLevel::error );
+ writeLog( "data.substr( 0, spacePos ) [" + data.substr( 0, spacePos ) + "]["+(string::npos == spacePos ? "" : data.substr( spacePos+1 ))+"]", logLevel::error );
+ writeLog( "npos: "+lexical_cast<string>(string::npos) + " - spacePos: + "+lexical_cast<string>(spacePos), logLevel::error );
//XHCPcommand command = 0;//commands[ QString(data).section( " ", 0, 0 ).toUpper() ];
XHCPcommand command = commands[ boost::algorithm::to_upper_copy( data.substr( 0, spacePos ) ) ];
- std::string parameters = std::string::npos == spacePos ? "" : data.substr( spacePos+1 );
+ string parameters = string::npos == spacePos ? "" : data.substr( spacePos+1 );
if( !command ) {
writeLog( "Error: Command not implemented! Request: [" + data + "]", logLevel::error );
@@ -170,7 +183,7 @@
}
writeLog( "Request: [" + data + "]", logLevel::debug );
- std::string result = (this->*command)( parameters );
+ string result = (this->*command)( parameters );
writeLog( "Result:\n[\n" + result + "]", logLevel::debug );
boost::asio::write(*sock, boost::asio::buffer(result));
}
@@ -180,7 +193,7 @@
writeLog( "XHCPThread::run() - end", logLevel::debug );
}
-std::string XHCPThread::commandNotRecognised( const std::string& parameter )
+string XHCPThread::commandNotRecognised( const string& parameter )
{
writeLog( "XHCPThread::commandNotRecognised( " + parameter + " )", logLevel::debug );
return responseCode( 500 );
@@ -213,15 +226,15 @@
_return = os.str();
}
- operator std::string() {
+ operator string() {
return _return;
}
private:
- std::string _return;
+ string _return;
};
-std::string XHCPThread::commandCapabilities( const std::string& parameter )
+string XHCPThread::commandCapabilities( const string& parameter )
{
writeLog( "XHCPThread::commandCapabilities( " + parameter + " )", logLevel::debug );
if( "" == parameter || "SCRIPTING" == parameter )
@@ -234,24 +247,24 @@
}
}
-std::string XHCPThread::commandDelGlobal( const std::string& parameter )
+string XHCPThread::commandDelGlobal( const string& parameter )
{
writeLog( "XHCPThread::commandDelGlobal( " + parameter + " )", logLevel::debug );
xPLCache->deleteEntry( parameter );
return responseCode( 233 );
}
-std::string XHCPThread::commandDelDevConfig( const std::string& parameter )
+string XHCPThread::commandDelDevConfig( const string& parameter )
{
writeLog( "XHCPThread::commandDelDevConfig( " + parameter + " )", logLevel::debug );
- deviceManager->removeConfig( parameter );
+ m_deviceManager->removeConfig( parameter );
return responseCode( 235 );
}
-std::string XHCPThread::commandGetDevConfig( const std::string& parameter )
+string XHCPThread::commandGetDevConfig( const string& parameter )
{
writeLog( "XHCPThread::commandGetDevConfig( " + parameter + " )", logLevel::debug );
- xPLDevice device = deviceManager->getDevice( parameter );
+ xPLDevice device = m_deviceManager->getDevice( parameter );
if( "" == device.VDI ) // empty string if device doesn't exist
return responseCode( 417 );
@@ -259,10 +272,10 @@
if( "" == device.ConfigSource )
return responseCode( 416 );
- std::string retval = responseCode( 217 );
+ string retval = responseCode( 217 );
boost::regex regex( "config\\." + device.VDI + "\\.options\\.([a-z0-9]{1,16})" );
- std::vector<std::string> entries = xPLCache->filterByRegEx( regex );
- for( std::vector<std::string>::const_iterator it = entries.begin(); it != entries.end(); ++it )
+ vector<string> entries = xPLCache->filterByRegEx( regex );
+ for( vector<string>::const_iterator it = entries.begin(); it != entries.end(); ++it )
{
boost::smatch matches;
if( boost::regex_match( *it, matches, regex ) )
@@ -276,26 +289,26 @@
return retval;
}
-std::string XHCPThread::commandGetDevConfigValue( const std::string& parameter )
+string XHCPThread::commandGetDevConfigValue( const string& parameter )
{
writeLog( "XHCPThread::commandGetDevConfigValue( " + parameter + " )", logLevel::debug );
- std::vector<std::string> list;
+ vector<string> list;
split( list, parameter, is_any_of( " " ) );
if( list.size() != 2 ) return responseCode( 501 ); // = syntax error
- std::string retval = responseCode( 234 );
+ string retval = responseCode( 234 );
// do we have to handle mutliple entries?
- std::string count = xPLCache->objectValue( "config." + list[0] + ".options." + list[1] + ".count" );
+ string count = xPLCache->objectValue( "config." + list[0] + ".options." + list[1] + ".count" );
if( "" == count )
{ // no
- std::string entry = xPLCache->objectValue( "config." + list[0] + ".current." + list[1] );
+ string entry = xPLCache->objectValue( "config." + list[0] + ".current." + list[1] );
if( "" != entry )
retval += list[1] + "=" + entry + newLine;
} else { // yes
- std::vector<std::string> entries = xPLCache->childNodes( "config." + list[0] + ".current." + list[1] );
- for( std::vector<std::string>::const_iterator it = entries.begin(); it != entries.end(); ++it )
+ vector<string> entries = xPLCache->childNodes( "config." + list[0] + ".current." + list[1] );
+ for( vector<string>::const_iterator it = entries.begin(); it != entries.end(); ++it )
{
- std::string entry = xPLCache->objectValue( *it );
+ string entry = xPLCache->objectValue( *it );
if( "" != entry )
retval += list[1] + "=" + entry + newLine;
}
@@ -304,26 +317,26 @@
return retval;
}
-std::string XHCPThread::commandListAllDevices( const std::string& parameter )
+string XHCPThread::commandListAllDevices( const string& parameter )
{
writeLog( "XHCPThread::commandListAllGlobals( " + parameter + " )", logLevel::debug );
- std::string result = responseCode( 216 );
- std::vector<std::string> names = deviceManager->getAllDeviceNames();
- for( std::vector<std::string>::const_iterator it = names.begin(); it != names.end(); ++it )
+ string result = responseCode( 216 );
+ vector<string> names = m_deviceManager->getAllDeviceNames();
+ for( vector<string>::const_iterator it = names.begin(); it != names.end(); ++it )
result += *it + newLine;
result += endMultiLine;
return result;
}
-std::string XHCPThread::commandListDevices( const std::string& parameter )
+string XHCPThread::commandListDevices( const string& parameter )
{
writeLog( "XHCPThread::commandListGlobals( " + parameter + " )", logLevel::debug );
- std::string result = responseCode( 216 );
- std::vector<std::string> names = deviceManager->getAllDeviceNames();
- std::string type = to_lower_copy( parameter );
- for( std::vector<std::string>::const_iterator it = names.begin(); it != names.end(); ++it )
+ string result = responseCode( 216 );
+ vector<string> names = m_deviceManager->getAllDeviceNames();
+ string type = to_lower_copy( parameter );
+ for( vector<string>::const_iterator it = names.begin(); it != names.end(); ++it )
{
- xPLDevice device = deviceManager->getDevice( *it );
+ xPLDevice device = m_deviceManager->getDevice( *it );
bool showDevice = true;
if( "awaitingconfig" == type && !device.ConfigType ) showDevice = false;
if( "configured" == type && device.ConfigType ) showDevice = false;
@@ -333,7 +346,7 @@
{
result += device.VDI + tab;
result += timeConverter( device.Expires ) + tab;
- result += lexical_cast<std::string>( device.Interval ) + tab;
+ result += lexical_cast<string>( device.Interval ) + tab;
result += (device.ConfigType ? "Y" : "N") + tab;
result += (device.ConfigDone ? "Y" : "N") + tab;
result += (device.WaitingConfig ? "Y" : "N") + tab;
@@ -344,19 +357,19 @@
return result;
}
-std::string XHCPThread::commandListGlobals( const std::string& parameter )
+string XHCPThread::commandListGlobals( const string& parameter )
{
writeLog( "XHCPThread::commandListGlobals( " + parameter + " )", logLevel::debug );
- std::string result = responseCode( 231 );
+ string result = responseCode( 231 );
result += xPLCache->listAllObjects();
result += endMultiLine;
return result;
}
-std::string XHCPThread::commandListOptions( const std::string& parameter )
+string XHCPThread::commandListOptions( const string& parameter )
{
writeLog( "XHCPThread::commandListOptions( " + parameter + " )", logLevel::debug );
- std::string result;
+ string result;
if( "" == parameter )
result = responseCode( 501 );
else
@@ -369,10 +382,10 @@
/**
* \brief List all determinator groups
*/
-std::string XHCPThread::commandListRuleGroups( const std::string& parameter )
+string XHCPThread::commandListRuleGroups( const string& parameter )
{
writeLog( "XHCPThread::commandListRuleGroups( " + parameter + " )", logLevel::debug );
- std::string result = responseCode( 240 );
+ string result = responseCode( 240 );
// FIXME add listing of groups
result += endMultiLine;
return result;
@@ -381,29 +394,29 @@
/**
* \brief List all determinators
*/
-std::string XHCPThread::commandListRules( const std::string& parameter )
+string XHCPThread::commandListRules( const string& parameter )
{
writeLog( "XHCPThread::commandListRules( " + parameter + " )", logLevel::debug );
- std::string result = responseCode( 237 );
+ string result = responseCode( 237 );
// FIXME add listing of groups
result += endMultiLine;
return result;
}
-std::string XHCPThread::commandPutDevConfig( const std::string& parameter )
+string XHCPThread::commandPutDevConfig( const string& parameter )
{
writeLog( "XHCPThread::commandPutDevConfig( " + parameter + " )", logLevel::debug );
- static std::string device;
+ static string device;
if( inMultilineRequest )
{
inMultilineRequest = false;
multilineRequestHandler = 0;
- if( deviceManager->storeNewConfig( device, parameter ) )
+ if( m_deviceManager->storeNewConfig( device, parameter ) )
return responseCode( 220 ); // storing succeded
else
return responseCode( 503 ); // storing failed
}
- if( !deviceManager->contains( parameter ) )
+ if( !m_deviceManager->contains( parameter ) )
return responseCode( 417 );
device = parameter;
@@ -412,11 +425,11 @@
return responseCode( 320 );
}
-std::string XHCPThread::commandSetGlobal( const std::string& parameter )
+string XHCPThread::commandSetGlobal( const string& parameter )
{
writeLog( "XHCPThread::commandSetGlobal( " + parameter + " )", logLevel::debug );
- std::vector<std::string> list;
+ vector<string> list;
split( list, parameter, is_any_of( " " ) );
if( list.size() != 2 ) return responseCode( 501 );
@@ -424,7 +437,7 @@
return responseCode( 232 );
}
-std::string XHCPThread::commandSendXPlMessage( const std::string& parameter )
+string XHCPThread::commandSendXPlMessage( const string& parameter )
{
writeLog( "XHCPThread::commandSendXPlMessage( " + parameter + " ) [inMultilineRequest="+(inMultilineRequest?"true":"false")+"]", logLevel::debug );
if( inMultilineRequest )
@@ -440,7 +453,7 @@
return responseCode( 313 );
}
-std::string XHCPThread::commandQuit( const std::string& parameter )
+string XHCPThread::commandQuit( const string& parameter )
{
writeLog( "XHCPThread::commandQuit( " + parameter + " )", logLevel::debug );
quit = true;
Modified: xPLHAL/branches/thomas_s_dev/src/xhcpthread.h
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xhcpthread.h 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/xhcpthread.h 2012-01-01 21:57:46 UTC (rev 624)
@@ -23,11 +23,12 @@
#include <boost/thread.hpp>
#include <boost/asio.hpp>
-
#include "xplcache.h"
typedef boost::shared_ptr<boost::asio::ip::tcp::tcp::socket> socket_ptr;
+class DeviceManager;
+
/**
* \brief Single connection to an xPLHAL Manager.
*
@@ -41,9 +42,10 @@
const std::string tab;
const std::string newLine;
const std::string endMultiLine;
+ DeviceManager* m_deviceManager;
public:
- XHCPThread( socket_ptr socket );
+ XHCPThread( socket_ptr socket, DeviceManager* dm );
~XHCPThread();
/** \brief The main loop of the thread. */
Modified: xPLHAL/branches/thomas_s_dev/src/xplcache.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xplcache.cpp 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/xplcache.cpp 2012-01-01 21:57:46 UTC (rev 624)
@@ -24,10 +24,17 @@
#include "xplcache.h"
-using namespace boost::algorithm;
-using namespace boost::posix_time;
-using namespace boost::filesystem;
+using boost::algorithm::starts_with;
+using boost::algorithm::iequals;
+using boost::algorithm::is_any_of;
+using boost::algorithm::split;
+using boost::posix_time::minutes;
+using boost::posix_time::second_clock;
+using boost::filesystem::path;
+using std::string;
+using std::vector;
+
timeStreamHelper timeConverter;
xPLCacheClass::CacheFilter::CacheFilter() :
@@ -35,10 +42,10 @@
mfInstance( "*" ), mfSchemType( "*" ), mfSchemClass( "*" ), expiry( false )
{}
-xPLCacheClass::CacheFilter::CacheFilter( const std::string& filter ) :
+xPLCacheClass::CacheFilter::CacheFilter( const string& filter ) :
prefTag( "cache" ), expiry( false )
{
- std::vector<std::string> list;
+ vector<string> list;
split( list, filter, is_any_of(".") );
mfType = list[0];
mfVendor = list[1];
@@ -53,16 +60,16 @@
loadCache();
}
-std::string xPLCacheClass::listAllObjects( bool forceEverything ) const
+string xPLCacheClass::listAllObjects( bool forceEverything ) const
{
writeLog( "xPLCacheClass::ListAllObjects()", logLevel::debug );
- std::string result;
+ string result;
shared_lock locker(cacheLock);
for( cacheMap::const_iterator it = cache.begin(); it != cache.end(); it++ )
{
- std::string name = it->first;
+ string name = it->first;
if( starts_with( name, "device." ) )
{
if( forceEverything || iequals( "true", cache.find("xplhal.showdevices")->second.value ) )
@@ -82,19 +89,19 @@
return result;
}
-void xPLCacheClass::updateEntry( const std::string& name, const std::string& value, const bool expires )
+void xPLCacheClass::updateEntry( const string& name, const string& value, const bool expires )
{
writeLog( "xPLCacheClass::updateEntry( \"" + name + "\", \"" + value + "\" )", logLevel::debug );
unique_lock locker(cacheLock);
cacheMap::iterator it = cache.find( name );
if( cache.end() == it )
- cache.insert( std::pair<std::string,CacheEntry>( name, CacheEntry( value, expires ) ) );
+ cache.insert( std::pair<string,CacheEntry>( name, CacheEntry( value, expires ) ) );
else
it->second = CacheEntry( value, expires );
}
-void xPLCacheClass::deleteEntry( const std::string& name )
+void xPLCacheClass::deleteEntry( const string& name )
{
writeLog( "xPLCacheClass::deleteEntry( \"" + name + "\" )", logLevel::debug );
unique_lock locker(cacheLock);
@@ -115,9 +122,9 @@
}
}
-std::vector<std::string> xPLCacheClass::childNodes( const std::string& filter ) const
+vector<string> xPLCacheClass::childNodes( const string& filter ) const
{
- std::vector<std::string> retval;
+ vector<string> retval;
for( cacheMap::const_iterator it = cache.begin(); it != cache.end(); ++it )
if( starts_with( it->first, filter ) )
@@ -126,9 +133,9 @@
return retval;
}
-std::vector<std::string> xPLCacheClass::filterByRegEx( const boost::regex& regex ) const
+vector<string> xPLCacheClass::filterByRegEx( const boost::regex& regex ) const
{
- std::vector<std::string> retval;
+ vector<string> retval;
for( cacheMap::const_iterator it = cache.begin(); it != cache.end(); ++it )
{
Modified: xPLHAL/branches/thomas_s_dev/src/xplhandler.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xplhandler.cpp 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/xplhandler.cpp 2012-01-01 21:57:46 UTC (rev 624)
@@ -18,7 +18,7 @@
#include <boost/algorithm/string/replace.hpp>
-using namespace boost::algorithm;
+using std::string;
#include "log.h"
@@ -31,7 +31,7 @@
int xPLHandler::m_refcount = 0;
-xPLHandler::xPLHandler( const std::string& host_name)
+xPLHandler::xPLHandler( const string& host_name)
: xPLService(0)
, m_exit_thread(false)
, vendor( "CHRISM" )
@@ -114,7 +114,7 @@
// send waiting messages
while( xPL_MessagePtr theMessage = xPLMessageQueue->consume( xPLService ) )
{
- writeLog("Found xPL message at " + lexical_cast<std::string>(theMessage)+ " to send...", logLevel::debug);
+ writeLog("Found xPL message at " + lexical_cast<string>(theMessage)+ " to send...", logLevel::debug);
if ( !xPL_sendMessage( theMessage ) )
writeLog("Unable to send xPL message", logLevel::debug);
else
@@ -126,29 +126,29 @@
}
}
-void xPLHandler::sendBroadcastMessage( const std::string& msgClass, const std::string& msgType, const xPLMessage::namedValueList& namedValues ) const
+void xPLHandler::sendBroadcastMessage( const string& msgClass, const string& msgType, const xPLMessage::namedValueList& namedValues ) const
{
writeLog( "xPLHandler::sendBroadcastMessage( "+msgClass+", "+msgType+" )", logLevel::debug );
xPLMessageQueue->add( xPLMessagePtr( new xPLMessage( xPL_MESSAGE_COMMAND, "*", "", "", msgClass, msgType, namedValues ) ) );
}
-void xPLHandler::sendMessage( const xPL_MessageType type, const std::string& tgtVendor, const std::string& tgtDeviceID,
- const std::string& tgtInstanceID, const std::string& msgClass, const std::string& msgType,
+void xPLHandler::sendMessage( const xPL_MessageType type, const string& tgtVendor, const string& tgtDeviceID,
+ const string& tgtInstanceID, const string& msgClass, const string& msgType,
const xPLMessage::namedValueList& namedValues ) const
{
- writeLog( "xPLHandler::sendMessage( "+lexical_cast<std::string>(type)+", "+tgtVendor+", "+tgtDeviceID+", "+tgtInstanceID+", "+msgClass+", "+msgType+" )", logLevel::debug );
+ writeLog( "xPLHandler::sendMessage( "+lexical_cast<string>(type)+", "+tgtVendor+", "+tgtDeviceID+", "+tgtInstanceID+", "+msgClass+", "+msgType+" )", logLevel::debug );
xPLMessageQueue->add( xPLMessagePtr( new xPLMessage( type, tgtVendor, tgtDeviceID, tgtInstanceID, msgClass, msgType, namedValues ) ) );
}
-void xPLHandler::sendMessage( const xPL_MessageType type, const std::string& VDI,
- const std::string& msgClass, const std::string& msgType,
+void xPLHandler::sendMessage( const xPL_MessageType type, const string& VDI,
+ const string& msgClass, const string& msgType,
const xPLMessage::namedValueList& namedValues ) const
{
size_t marker1 = VDI.find( "-" );
size_t marker2 = VDI.find( "." );
- std::string vendor = VDI.substr( 0, marker1 );
- std::string device = VDI.substr( marker1+1, marker2 - (marker1+1) );
- std::string instance = VDI.substr( marker2+1 );
+ string vendor = VDI.substr( 0, marker1 );
+ string device = VDI.substr( marker1+1, marker2 - (marker1+1) );
+ string instance = VDI.substr( marker2+1 );
xPLMessageQueue->add( xPLMessagePtr( new xPLMessage( type, vendor, device, instance, msgClass, msgType, namedValues ) ) );
}
Modified: xPLHAL/branches/thomas_s_dev/src/xplmessage.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xplmessage.cpp 2012-01-01 21:56:16 UTC (rev 623)
+++ xPLHAL/branches/thomas_s_dev/src/xplmessage.cpp 2012-01-01 21:57:46 UTC (rev 624)
@@ -20,10 +20,11 @@
#include <boost/lexical_cast.hpp>
#include <algorithm>
-using namespace boost::algorithm;
+using boost::algorithm::replace_all;
using boost::lexical_cast;
+using std::string;
-std::string xPLMessage::getTypeString() const
+string xPLMessage::getTypeString() const
{
switch(type)
{
@@ -34,17 +35,17 @@
}
}
-std::string xPLMessage::getSourceVDI() const
+string xPLMessage::getSourceVDI() const
{
- return vendor + std::string("-") + deviceID + std::string(".") + instanceID;
+ return vendor + string("-") + deviceID + string(".") + instanceID;
}
-std::string xPLMessage::getTargetVDI() const
+string xPLMessage::getTargetVDI() const
{
- return targetVendor + std::string("-") + targetDevice + std::string(".") + targetInstance;
+ return targetVendor + string("-") + targetDevice + string(".") + targetInstance;
}
-bool xPLMessage::setSourceFromVDI(const std::string& source)
+bool xPLMessage::setSourceFromVDI(const string& source)
{
size_t marker1 = source.find( "-" );
size_t marker2 = source.find( "." );
@@ -55,7 +56,7 @@
return true;
}
-bool xPLMessage::setTargetFromVDI(const std::string& target)
+bool xPLMessage::setTargetFromVDI(const string& target)
{
if (target == "*") {
isBroadcastMessage = true;
@@ -72,7 +73,7 @@
return true;
}
-std::string xPLMessage::getNamedValue(const std::string& tag) const
+string xPLMessage::getNamedValue(const string& tag) const
{
for (auto entry : namedValues) {
if (entry.first == tag) {
@@ -82,9 +83,9 @@
return "";
}
-std::string xPLMessage::printXPLMessage() const
+string xPLMessage::printXPLMessage() const
{
- std::string result;
+ string result;
result += "<" + getTypeString() + " ";
/* Source Info */
@@ -102,7 +103,7 @@
}
/* Print hop count */
- result += " (" + lexical_cast<std::string>(hopcount) + " hops) ";
+ result += " (" + lexical_cast<string>(hopcount) + " hops) ";
/* Echo Schema Info */
result += "[" + msgClass + "." + msgType + "]: ";
@@ -136,7 +137,7 @@
return true;
}
-xPLMessage::operator std::string() const
+xPLMessage::operator string() const
{
return printXPLMessage();
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tho...@us...> - 2012-01-01 21:56:22
|
Revision: 623
http://openautomation.svn.sourceforge.net/openautomation/?rev=623&view=rev
Author: thomas_s
Date: 2012-01-01 21:56:16 +0000 (Sun, 01 Jan 2012)
Log Message:
-----------
- improved recurring timer
- refactored main function as Object
Modified Paths:
--------------
xPLHAL/branches/thomas_s_dev/src/main.cpp
xPLHAL/branches/thomas_s_dev/src/recurring_timer.cpp
xPLHAL/branches/thomas_s_dev/src/recurring_timer.h
Modified: xPLHAL/branches/thomas_s_dev/src/main.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/main.cpp 2012-01-01 20:50:01 UTC (rev 622)
+++ xPLHAL/branches/thomas_s_dev/src/main.cpp 2012-01-01 21:56:16 UTC (rev 623)
@@ -24,29 +24,115 @@
// load globas and give them their space to live
#include "globals.h"
-using namespace boost::filesystem;
+using boost::filesystem::path;
+using boost::filesystem::initial_path;
+
path xPLHalRootFolder;
path DataFileFolder;
path ScriptEngineFolder;
path rulesFolder;
xPLCacheClass *xPLCache;
-deviceManagerClass *deviceManager;
xPLHandler *xPL;
xPLMessageQueueClass *xPLMessageQueue;
-
+
static boost::asio::io_service* g_ioservice = nullptr;
+class XplHalApplication
+{
+ public:
+ XplHalApplication()
+ :mXplMessageQueue(new xPLMessageQueueClass)
+ ,mXplCache(new xPLCacheClass)
+ ,mDeviceManager(mXplCache)
+ ,mXHCPServer(new XHCPServer(m_ioservice, &mDeviceManager))
+ ,mXpl(new xPLHandler( boost::asio::ip::host_name() ))
+ ,mTimerListAllObjects(m_ioservice, boost::posix_time::seconds(60), true)
+ ,mTimerFlushExpiredEntries(m_ioservice, boost::posix_time::minutes(5), true)
+ {
+ mDeviceManager.m_sigSendXplMessage.connect(boost::bind(&xPLMessageQueueClass::add, mXplMessageQueue, _1));
+ mXpl->m_sigRceivedXplMessage.connect(boost::bind(&DeviceManager::processXplMessage, &mDeviceManager, _1));
+ installTimer();
+
+ /* set global variables */
+ xPLCache = mXplCache;
+ xPL = mXpl;
+ xPLMessageQueue = mXplMessageQueue;
+
+ writeLog( "initialized", logLevel::all );
+ }
+
+ ~XplHalApplication()
+ {
+ // clean up
+ delete mXHCPServer;
+ writeLog( "main: xhcp shutdown", logLevel::all );
+ // delete deviceManager;
+ // writeLog( "main: deviceManager shutdown", logLevel::all );
+ delete mXplCache;
+ writeLog( "main: xPLCache shutdown", logLevel::all );
+ delete mXpl;
+ writeLog( "main: xPL shutdown", logLevel::all );
+ }
+
+ void installTimer()
+ {
+ mTimerListAllObjects.sigExpired.connect([](const boost::system::error_code& e) {
+ writeLog( "main: <tick>", logLevel::all );
+ writeLog( "xPLCache:\n" + xPLCache->listAllObjects(), logLevel::debug );
+ });
+
+ mTimerFlushExpiredEntries.sigExpired.connect([](const boost::system::error_code& e) {
+ writeLog( "main: flush cache", logLevel::all );
+ xPLCache->flushExpiredEntries(); // flush cache
+ });
+ }
+
+ static void stop()
+ {
+ m_ioservice.stop();
+ }
+
+ int exec()
+ {
+ // force everyone to send their configuration so that we start up to date...
+ xPLMessageQueue->add(xPLMessagePtr( new xPLMessage(xPL_MESSAGE_COMMAND, "*", "config", "current", {{"command", "request"}}) ));
+
+ writeLog( "started, run mainloop", logLevel::all );
+ m_ioservice.run();
+ writeLog( "main: shutdown xPLHal", logLevel::all );
+ return 0;
+ }
+
+ static void dispatchEvent(void (*event)())
+ {
+ m_ioservice.dispatch(event);
+ }
+
+ private:
+ static boost::asio::io_service m_ioservice;
+
+ xPLMessageQueueClass *mXplMessageQueue;
+ xPLCacheClass *mXplCache;
+ DeviceManager mDeviceManager;
+ XHCPServer *mXHCPServer;
+ xPLHandler *mXpl;
+
+ RecurringTimer mTimerListAllObjects;
+ RecurringTimer mTimerFlushExpiredEntries;
+};
+
+boost::asio::io_service XplHalApplication::m_ioservice;
+
void handle_signal(int signal)
{
if (signal == SIGINT || signal == SIGTERM) {
- if (g_ioservice) {
- g_ioservice->stop();
- }
+ XplHalApplication::stop();
}
}
+
/**
* Setup the whole program.
*/
@@ -64,82 +150,37 @@
signal(SIGTERM, handle_signal);
// FIXME : add exception handling for directory operations!!!
- if(false)//FIXME if( !QDir::setCurrent( xPLHalRootFolder.path() ) )
- {
+ if(false) {
+ //FIXME if( !QDir::setCurrent( xPLHalRootFolder.path() ) )
writeLog( "Error changing to working directory \"" + xPLHalRootFolder.string() + "\"!", logLevel::error );
return -1;
}
- if( !exists( DataFileFolder ) )
- {
+ if( !exists( DataFileFolder ) ) {
writeLog( "Directory \"" + DataFileFolder.string() + "\" for DataFileFolder doesn't exist. Creating it...", logLevel::debug );
- if( !create_directory( DataFileFolder ) )
- {
+ if( !create_directory( DataFileFolder ) ) {
writeLog( "Error creating data directory \"" + DataFileFolder.string() + "\"!", logLevel::error );
return -1;
}
}
- if( !exists( ScriptEngineFolder ) )
- {
+ if( !exists( ScriptEngineFolder ) ) {
writeLog( "Directory \"" + ScriptEngineFolder.string() + "\" for ScriptEngineFolder doesn't exist. Creating it...", logLevel::debug );
- if( !create_directory( ScriptEngineFolder ) )
- {
+ if( !create_directory( ScriptEngineFolder ) ) {
writeLog( "Error creating script directory \"" + ScriptEngineFolder.string() + "\"!", logLevel::error );
return -1;
}
}
- if( !exists( rulesFolder ) )
- {
+ if( !exists( rulesFolder ) ) {
writeLog( "Directory \"" + rulesFolder.string() + "\" for rulesFolder doesn't exist. Creating it...", logLevel::debug );
- if( !create_directory( rulesFolder ) )
- {
+ if( !create_directory( rulesFolder ) ) {
writeLog( "Error creating determinator directory \"" + rulesFolder.string() + "\"!", logLevel::error );
return -1;
}
}
-
- boost::asio::io_service io;
- g_ioservice = &io;
- xPLMessageQueue = new xPLMessageQueueClass;
- xPLCache = new xPLCacheClass;
- XHCPServer *xhcpServer = new XHCPServer(io);
- xPL = new xPLHandler( boost::asio::ip::host_name() ); //xPL->start();
- deviceManager = new deviceManagerClass(xPLCache);
- deviceManager->m_sigSendXplMessage.connect(boost::bind(&xPLMessageQueueClass::add, xPLMessageQueue, _1));
- xPL->m_sigRceivedXplMessage.connect(boost::bind(&deviceManagerClass::processXplMessage, deviceManager, _1));
- writeLog( "started", logLevel::all );
+ XplHalApplication app;
+ return app.exec();
+}
- // force everyone to send their configuration so that we start up to date...
- xPLMessage::namedValueList command_request; command_request.push_back( std::make_pair( "command", "request" ) );
- xPL->sendBroadcastMessage( "config", "list", command_request );
-
- RecurringTimer timer_listAllObjects(io, boost::posix_time::seconds(60), true);
- timer_listAllObjects.setExpireHandler([](const boost::system::error_code& e) {
- writeLog( "main: <tick>", logLevel::all );
- writeLog( "xPLCache:\n" + xPLCache->listAllObjects(), logLevel::debug );
- });
-
- RecurringTimer timer_flushExpiredEntries(io, boost::posix_time::minutes(5), true);
- timer_flushExpiredEntries.setExpireHandler([](const boost::system::error_code& e) {
- writeLog( "main: flush cache", logLevel::all );
- xPLCache->flushExpiredEntries(); // flush cache
- });
-
- io.run();
- g_ioservice = nullptr;
-
- writeLog( "main: shutdown xPLHal", logLevel::all );
-
- // clean up
- delete xhcpServer;
- writeLog( "main: xhcp shutdown", logLevel::all );
- delete deviceManager;
- writeLog( "main: deviceManager shutdown", logLevel::all );
- delete xPLCache;
- writeLog( "main: xPLCache shutdown", logLevel::all );
- delete xPL;
- writeLog( "main: xPL shutdown", logLevel::all );
-}
Modified: xPLHAL/branches/thomas_s_dev/src/recurring_timer.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/recurring_timer.cpp 2012-01-01 20:50:01 UTC (rev 622)
+++ xPLHAL/branches/thomas_s_dev/src/recurring_timer.cpp 2012-01-01 21:56:16 UTC (rev 623)
@@ -24,7 +24,6 @@
:m_timer(io_service, expiry_time)
,m_delay(expiry_time)
,m_running(false)
-,m_expireFunc(nullptr)
{
if (startTimer) {
start();
@@ -36,11 +35,6 @@
stop();
}
-void RecurringTimer::setExpireHandler(void (*handler)(const boost::system::error_code& e))
-{
- m_expireFunc = handler;
-}
-
void RecurringTimer::start()
{
m_running = true;
@@ -59,8 +53,6 @@
m_timer.expires_at(m_timer.expires_at() + m_delay);
m_timer.async_wait(boost::bind(&RecurringTimer::onExpire, this, _1));
}
- if (m_expireFunc) {
- m_expireFunc(e);
- }
+ sigExpired(e);
}
Modified: xPLHAL/branches/thomas_s_dev/src/recurring_timer.h
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/recurring_timer.h 2012-01-01 20:50:01 UTC (rev 622)
+++ xPLHAL/branches/thomas_s_dev/src/recurring_timer.h 2012-01-01 21:56:16 UTC (rev 623)
@@ -18,6 +18,7 @@
*/
#include <boost/asio.hpp>
+#include <boost/signals2/signal.hpp>
class RecurringTimer
{
@@ -25,10 +26,10 @@
RecurringTimer(boost::asio::io_service& io_service, const boost::asio::deadline_timer::duration_type& expiry_time, bool startTimer = false);
~RecurringTimer();
- void setExpireHandler(void (*handler)(const boost::system::error_code& e));
-
void start();
void stop();
+
+ boost::signals2::signal<void (const boost::system::error_code& e)> sigExpired;
private:
void onExpire(const boost::system::error_code& e);
@@ -36,6 +37,5 @@
const boost::asio::deadline_timer::duration_type m_delay;
bool m_running;
boost::asio::deadline_timer m_timer;
- void (*m_expireFunc)(const boost::system::error_code&);
};
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2012-01-01 20:50:08
|
Revision: 622
http://openautomation.svn.sourceforge.net/openautomation/?rev=622&view=rev
Author: makki1
Date: 2012-01-01 20:50:01 +0000 (Sun, 01 Jan 2012)
Log Message:
-----------
WireGate-Plugins: Cleanup SMTP-Watchdog and example, add error-handling
Modified Paths:
--------------
wiregate/plugin/generic/SMTP-eMail.pl
wiregate/plugin/generic/Watchdog-SMTP-eMail
Modified: wiregate/plugin/generic/SMTP-eMail.pl
===================================================================
--- wiregate/plugin/generic/SMTP-eMail.pl 2011-12-31 18:20:12 UTC (rev 621)
+++ wiregate/plugin/generic/SMTP-eMail.pl 2012-01-01 20:50:01 UTC (rev 622)
@@ -11,7 +11,6 @@
##################
my $Empfaenger = 'me...@do...'; # Anpassen, mehrere mit ,
-
my $Absender = 'WireGate <ab...@gm...>'; # unbedingt anpassen, die Absenderadresse sollte gültig sein um Probleme zu vermeiden
my $Betreff = "eMail von $hostname";
my $text = "email-Body";
@@ -27,29 +26,29 @@
use Net::SMTP;
use MIME::Base64;
-my $smtp = Net::SMTP->new($mailserver, Timeout => 5, Debug =>1) or return "Fehler beim verbinden zu $mailserver $!";
-my $ret .= ' auth:'. $smtp->auth($username,$password);
+my $smtp = Net::SMTP->new($mailserver, Timeout => 20, Debug =>1) or return "Fehler beim verbinden zu $mailserver $!; $@";
+$smtp->auth($username,$password);
$smtp->status() < 5
or do {
- # Die smtp->auth Methode schlaegt fehl, also dann so
- $smtp->datasend("AUTH LOGIN\n") or return 'auth login problem';
+ #Die smtp->auth Methode schlaegt fehl, also dann so
+ $smtp->datasend("AUTH LOGIN\n") or return 'auth login problem $!';
$smtp->response();
- $smtp->datasend(encode_base64( $username ) ) or return "username $username cannot be encoded or wrong";
+ $smtp->datasend(encode_base64( $username ) ) or return "username $username cannot be encoded or wrong $!";
$smtp->response();
- $smtp->datasend(encode_base64( $password ) ) or return "password $password cannot be encoded or wrong";
+ $smtp->datasend(encode_base64( $password ) ) or return "password $password cannot be encoded or wrong $!";
$smtp->response();
};
-$ret .= 'status:' . $smtp->status();
-$ret .= ' send:'. $smtp->mail($Absender);
-$ret .= ' rcpt:'. $smtp->to($Empfaenger);
-$ret .= $smtp->data();
-$ret .= $smtp->datasend("To: $Empfaenger\n"); # Empfänger (Header)
-$ret .= $smtp->datasend("Subject: $Betreff\n"); # Betreff
-$ret .= $smtp->datasend("\n");
-$ret .= $smtp->datasend("$text\n");
-$ret .= $smtp->dataend();
-$ret .= $smtp->quit;
+$smtp->status() < 5 or return "Auth failed: $! ". $smtp->status();
+$smtp->mail($Absender) or return "Absender $Absender abgelehnt $!";
+$smtp->to($Empfaenger) or return "Empfaenger $Empfaenger abgelehnt $!";
+$smtp->data() or return "Data failed $!";
+$smtp->datasend("To: $Empfaenger\n") or return "Empfanger $Empfaenger (Header-To) abgelehnt $!";
+$smtp->datasend("Subject: $Betreff\n") or return "Subject $Betreff abgelehnt $!";
+$smtp->datasend("\n") or return "Data failed $!";
+$smtp->datasend("$text\n") or return "Data failed $!";
+$smtp->dataend() or return "Data failed $!";
+$smtp->quit or return "Quit failed $!";
-# FIXME: check if we succeeded
-return;
+return; # keine Logausgabe
+return "eMail von $Absender an $Empfaenger Betreff $Betreff gesendet: $text";
Modified: wiregate/plugin/generic/Watchdog-SMTP-eMail
===================================================================
--- wiregate/plugin/generic/Watchdog-SMTP-eMail 2011-12-31 18:20:12 UTC (rev 621)
+++ wiregate/plugin/generic/Watchdog-SMTP-eMail 2012-01-01 20:50:01 UTC (rev 622)
@@ -1,17 +1,30 @@
-# Demo-Plugin zum prüfen auf Timeout-Fehler und eMail-Versand
-use Net::SMTP;
+# Demo-Plugin zum prüfen auf Plugin Timeout-Fehler
+# und eMail-Versand
-my $Empfaenger = 'me...@ke...';
-my $Absender = 'WireGate <wir...@el...>';
-my $Betreff = "Plugin-Alarm!";
-my $mailserver='mail-out.elabnet.de'; # SMTP-Relay: das muss natuerlich angepasst werden!
-# Das kann tricky sein mit GMX&co..
-# Fix-me: besser waere den lokale Exim-Mailserver zu verwenden
-# Dieser muesste jedoch erst mit einem entspr. Relay konfiguriert werden
+my $hostname = `hostname`;
+##################
+### DEFINITION ###
+##################
+
+my $Empfaenger = 'me...@do...'; # Anpassen, mehrere mit ,
+my $Absender = 'WireGate <ab...@gm...>'; # unbedingt anpassen, die Absenderadresse sollte gültig sein um Probleme zu vermeiden
+my $Betreff = "Plugin-Alarm von $hostname !";
+my $username = 'ab...@gm...'; #Anpassen! Username fuer SMTP-Server
+my $password = "meinpasswort"; #Anpassen! Passwort fuer SMTP-Server
+my $mailserver='mail.gmx.net'; # SMTP-Relay: das muss natuerlich angepasst werden!
$plugin_info{$plugname.'_cycle'} = 300;
-my $ret;
+#######################
+### ENDE DEFINITION ###
+#######################
+
+use Net::SMTP;
+use MIME::Base64;
+# FIXME: require Authen/SASL ?
+
+my ($ret,$err);
+
foreach (@plugins) {
my $plugname2 = basename($_);
if ($plugin_info{$plugname2.'_timeout_err'} >= $plugin_max_errors) {
@@ -19,18 +32,31 @@
# Alert
if (!$plugin_info{$plugname2.'_timeout_alarm'}) {
# sende Warn-eMail
- my $smtp = Net::SMTP->new($mailserver, Timeout => 5);
- $smtp->mail($Absender);
- $smtp->to($Empfaenger);
- $smtp->data();
- $smtp->datasend("To: $Empfaenger\n"); # Empfänger (Header)
- $smtp->datasend("Subject: $Betreff\n"); # Betreff
- $smtp->datasend("\n");
- $smtp->datasend("$ret\n");
- $smtp->dataend();
- $smtp->quit;
- }
- $plugin_info{$plugname2.'_timeout_alarm'} = 1;
+ my $smtp = Net::SMTP->new($mailserver, Timeout => 20, Debug =>1) or return "Fehler beim verbinden zu $mailserver $!; $@";
+ $smtp->auth($username,$password);
+ $smtp->status() < 5
+ or do {
+ #Die smtp->auth Methode schlaegt fehl, also dann so
+ $smtp->datasend("AUTH LOGIN\n") or return 'auth login problem $!';
+ $smtp->response();
+ $smtp->datasend(encode_base64( $username ) ) or return "username $username cannot be encoded or wrong $!";
+ $smtp->response();
+ $smtp->datasend(encode_base64( $password ) ) or return "password $password cannot be encoded or wrong $!";
+ $smtp->response();
+ };
+ $smtp->status() < 5 or return "Auth failed: $! ". $smtp->status();
+ $smtp->mail($Absender) or return "Absender $Absender abgelehnt $!";
+ $smtp->to($Empfaenger) or return "Empfaenger $Empfaenger abgelehnt $!";
+ $smtp->data() or return "Data failed $!";
+ $smtp->datasend("To: $Empfaenger\n") or return "Empfanger $Empfaenger (Header-To) abgelehnt $!";
+ $smtp->datasend("Subject: $Betreff\n") or return "Subject $Betreff abgelehnt $!";
+ $smtp->datasend("\n") or return "Data failed $!";
+ $smtp->datasend("$ret\n") or return "Data failed $!";
+ $smtp->dataend() or return "Data failed $!";
+ $smtp->quit or return "Quit failed $!";
+ $plugin_info{$plugname2.'_timeout_alarm'} = 1;
+ return "eMail gesendet: $ret";
+ }
} else {
# Reset Merker
$plugin_info{$plugname2.'_timeout_alarm'} = 0;
@@ -38,5 +64,5 @@
#$ret .= "$plugname2 Timeouts: $plugin_info{$plugname2.'_timeout_err'}";
}
-return $ret;
+return; #alles ok oder eMail bereits gesendet
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tho...@us...> - 2011-12-31 18:20:18
|
Revision: 621
http://openautomation.svn.sourceforge.net/openautomation/?rev=621&view=rev
Author: thomas_s
Date: 2011-12-31 18:20:12 +0000 (Sat, 31 Dec 2011)
Log Message:
-----------
refactored testcases in test_devicemanager
Modified Paths:
--------------
xPLHAL/branches/thomas_s_dev/test/test_devicemanager.cpp
Modified: xPLHAL/branches/thomas_s_dev/test/test_devicemanager.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/test/test_devicemanager.cpp 2011-12-31 18:18:39 UTC (rev 620)
+++ xPLHAL/branches/thomas_s_dev/test/test_devicemanager.cpp 2011-12-31 18:20:12 UTC (rev 621)
@@ -1,54 +1,24 @@
#include "../src/devicemanager.h"
#define BOOST_TEST_MODULE "DeviceManager"
#include <boost/test/unit_test.hpp>
-//#include "mock_xplhandler.h"
+#include <mockpp/visiting/CountedVisitableMethod.h>
-//#include "xplcache.h"
+using namespace mockpp;
+
#include "devicemanager.h"
#include <boost/regex.hpp>
-// load globas and give them their space to live
-//#include "globals.h"
-
-#if 0
-using namespace boost::filesystem;
-path xPLHalRootFolder;
-path DataFileFolder;
-path ScriptEngineFolder;
-path rulesFolder;
-#endif
-
-
-#if 0
-class MockXplHandler: public IxPLHandler
+xPLMessagePtr createXplMessage(xPL_MessageType type, const std::string& srcVDI, const std::string& dstVDI,
+ const std::string& msgClass, const std::string& msgType, xPLMessage::namedValueList list)
{
- public:
- void sendBroadcastMessage( const std::string& msgClass, const std::string& msgType, const xPLMessage::namedValueList& namedValues ) const
- {
- std::cerr << "sendBroadcastMessage(" << msgClass;
- std::cerr << std::endl;
- }
+ xPLMessagePtr msg( new xPLMessage(type, srcVDI,
+ msgClass, msgType,
+ list));
+ msg->setTargetFromVDI(dstVDI);
+ return msg;
+}
- /** \brief Send a directed message to the xPL network. */
- void sendMessage( const xPL_MessageType type, const std::string& tgtVendor, const std::string& tgtDeviceID,
- const std::string& tgtInstanceID, const std::string& msgClass, const std::string& msgType,
- const xPLMessage::namedValueList& namedValues ) const
- {
- std::cerr << "sendMessage";
- std::cerr << std::endl;
- }
-
- /** \brief Send a directed message to the xPL network. */
- void sendMessage( const xPL_MessageType type, const std::string& VDI,
- const std::string& msgClass, const std::string& msgType, const xPLMessage::namedValueList& namedValues ) const
- {
- std::cerr << "sendMessage";
- std::cerr << std::endl;
- }
-};
-#endif
-
class MockXplCache: public IxPLCacheClass
{
/** \returns true if the element name exists. */
@@ -88,45 +58,27 @@
virtual void saveCache( void ) const { }
};
-class MockSignalReceiver
+class MockSignalReceiver : public VisitableMockObject
{
public:
- void handleSignal(const xPLMessagePtr message)
+ MockSignalReceiver()
+ :VisitableMockObject("MockSignalReceiver", 0)
+ ,handleSignal_mocker("handleSignal", this)
+ {}
+
+ virtual void handleSignal(const xPLMessagePtr message)
{
std::cout << "received signal" << *message << std::endl;
+ handleSignal_mocker.forward(*message);
}
+ VisitableMockMethod<void, xPLMessage> handleSignal_mocker;
};
BOOST_AUTO_TEST_SUITE(DeviceManagerSuite);
BOOST_AUTO_TEST_CASE( add_device )
{
- xPLMessage::namedValueList values;
- values.push_back( std::make_pair( "tag", "value" ) );
- xPLMessagePtr msg( new xPLMessage(xPL_MESSAGE_TRIGGER,
- "pnxs", "hs485", "default1",
- "blah", "blub",
- values) );
-#if 0
- xPL_MessagePtr msg = new xPL_Message;
- msg->messageType = xPL_MESSAGE_TRIGGER;
- msg->hopCount = 0;
- msg->receivedMessage = TRUE; /* TRUE if received, FALSE if being sent */
- msg->sourceVendor = "pnxs";
- msg->sourceDeviceID = "hs485";
- msg->sourceInstanceID = "default1";
- msg->isGroupMessage = FALSE;
- msg->groupName = 0;
- msg->isBroadcastMessage = TRUE;
- msg->targetVendor = "*";
- msg->targetDeviceID = "";
- msg->targetInstanceID = "";
- msg->schemaClass = "blah";
- msg->schemaType = "blub";
- xPL_addMessageNamedValue(msg, "tag", "value");
-#endif
-
-// MockXplHandler mockHandler;
+ xPLMessagePtr msg( createXplMessage(xPL_MESSAGE_TRIGGER, "pnxs-hs485.default1", "*", "blah", "blub", {{"tag", "value"}}));
MockXplCache mockCache;
deviceManagerClass dm(&mockCache);
@@ -135,87 +87,16 @@
BOOST_CHECK( dm.contains("pnxs-hs485.default1") == true);
}
-#define m2s(match, group) std::string(match[group].first, match[group].second)
-//xPL_MessagePtr createXplMessage(const char* srcVDI, const char* dstVDI, const char* schema, std::map<std::string, std::string> tags)
-xPL_MessagePtr createXplMessage(xPL_MessageType msgType, const std::string& srcVDI, const std::string& dstVDI, const char* schema)
-{
- std::string regex = R"(^([\w\d]+)-([\w\d]+)\.([\w\d]+)$)";
- xPL_MessagePtr msg = new xPL_Message;
- msg->messageType = msgType;
- msg->hopCount = 0;
- msg->receivedMessage = TRUE; /* TRUE if received, FALSE if being sent */
- msg->isGroupMessage = FALSE;
- msg->groupName = 0;
- msg->isBroadcastMessage = TRUE;
- msg->schemaClass = "blah";
- msg->schemaType = "blub";
-// xPL_addMessageNamedValue(msg, "tag", "value");
-
-
- boost::regex re_vdi(regex);
- boost::smatch match;
- if( ! boost::regex_match(srcVDI, match, re_vdi) ) {
- delete msg;
- return 0;
- }
- msg->sourceVendor = m2s(match, 1).c_str();
- msg->sourceDeviceID = m2s(match, 2).c_str();
- msg->sourceInstanceID = m2s(match, 3).c_str();
-
- if( dstVDI == "*") {
- msg->targetVendor = "*";
- msg->targetDeviceID = "";
- msg->targetInstanceID = "";
- }
- else {
- if( ! boost::regex_match(dstVDI, match, re_vdi) ) {
- delete msg;
- return 0;
- }
- }
- msg->targetVendor = m2s(match, 1).c_str();
- msg->targetDeviceID = m2s(match, 2).c_str();
- msg->targetInstanceID = m2s(match, 3).c_str();
-
- return 0;
-}
-
BOOST_AUTO_TEST_CASE( remove_device )
{
-// xPL_MessagePtr mymsg = createXplMessage(xPL_MESSAGE_TRIGGER, "pnxs-hs485.default1", "*", "blah.blub");
- xPLMessage::namedValueList values;
- values.push_back( std::make_pair( "tag", "value" ) );
- xPLMessagePtr msg( new xPLMessage(xPL_MESSAGE_TRIGGER,
- "pnxs", "hs485", "default1",
- "blah", "blub",
- values) );
-#if 0
- xPL_MessagePtr msg = new xPL_Message;
- msg->messageType = xPL_MESSAGE_TRIGGER;
- msg->hopCount = 0;
- msg->receivedMessage = TRUE; /* TRUE if received, FALSE if being sent */
- msg->sourceVendor = "pnxs";
- msg->sourceDeviceID = "hs485";
- msg->sourceInstanceID = "default1";
- msg->isGroupMessage = FALSE;
- msg->groupName = 0;
- msg->isBroadcastMessage = TRUE;
- msg->targetVendor = "*";
- msg->targetDeviceID = "";
- msg->targetInstanceID = "";
- msg->schemaClass = "blah";
- msg->schemaType = "blub";
- xPL_addMessageNamedValue(msg, "tag", "value");
-#endif
+ xPLMessagePtr msg( createXplMessage(xPL_MESSAGE_TRIGGER, "pnxs-hs485.default1", "*", "blah", "blub", {{"tag", "value"}}));
-// MockXplHandler mockHandler;
MockXplCache mockCache;
MockSignalReceiver sigrecv;
-// xPLMessage::namedValueList nvl;
-// mockHandler.sendMessage(xPL_MESSAGE_COMMAND, "pnxs", "hs485", "default1", "config", "list", nvl);
-// mockHandler.activate();
+ sigrecv.handleSignal(createXplMessage(xPL_MESSAGE_COMMAND, "pnxs-hs485.default1", "*", "config", "list", {{"command", "request"}}));
+ sigrecv.activate();
deviceManagerClass dm(&mockCache);
dm.m_sigSendXplMessage.connect(boost::bind(&MockSignalReceiver::handleSignal, &sigrecv, _1));
@@ -227,7 +108,7 @@
dm.processRemove(msg);
BOOST_CHECK( dm.contains("pnxs-hs485.default1") == false);
- //mockHandler.verify();
+ sigrecv.verify();
}
BOOST_AUTO_TEST_SUITE_END();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tho...@us...> - 2011-12-31 18:18:46
|
Revision: 620
http://openautomation.svn.sourceforge.net/openautomation/?rev=620&view=rev
Author: thomas_s
Date: 2011-12-31 18:18:39 +0000 (Sat, 31 Dec 2011)
Log Message:
-----------
replaced main-loop by boost::asio::io_service
implemented 'events' in main-loop with recurring-timer (boost::asio::deadline_timer)
XHCP now uses io_service given in constructor
Modified Paths:
--------------
xPLHAL/branches/thomas_s_dev/src/CMakeLists.txt
xPLHAL/branches/thomas_s_dev/src/main.cpp
xPLHAL/branches/thomas_s_dev/src/xhcp.cpp
xPLHAL/branches/thomas_s_dev/src/xhcp.h
Added Paths:
-----------
xPLHAL/branches/thomas_s_dev/src/recurring_timer.cpp
xPLHAL/branches/thomas_s_dev/src/recurring_timer.h
Modified: xPLHAL/branches/thomas_s_dev/src/CMakeLists.txt
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/CMakeLists.txt 2011-12-31 18:16:57 UTC (rev 619)
+++ xPLHAL/branches/thomas_s_dev/src/CMakeLists.txt 2011-12-31 18:18:39 UTC (rev 620)
@@ -19,7 +19,9 @@
#set(CMAKE_CXX_FLAGS "-g -O2 -std=c++0x")
set(CMAKE_CXX_FLAGS "-g -Os -std=c++0x")
-set(xPLHAL_SRCS xplmessagequeue.cpp devicemanager.cpp xplhandler.cpp xplcache.cpp xhcpthread.cpp log.cpp xhcp.cpp xplmessage.cpp main.cpp)
+set(xPLHAL_SRCS xplmessagequeue.cpp devicemanager.cpp
+ xplhandler.cpp xplcache.cpp xhcpthread.cpp log.cpp
+ xhcp.cpp xplmessage.cpp recurring_timer.cpp main.cpp)
add_executable(xPLHAL ${xPLHAL_SRCS})
#message(STATUS "Boost_LIBRARIES=${Boost_LIBRARIES}")
Modified: xPLHAL/branches/thomas_s_dev/src/main.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/main.cpp 2011-12-31 18:16:57 UTC (rev 619)
+++ xPLHAL/branches/thomas_s_dev/src/main.cpp 2011-12-31 18:18:39 UTC (rev 620)
@@ -15,12 +15,12 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-
#include <signal.h>
#include "log.h"
#include "xplcache.h"
#include "devicemanager.h"
#include "xhcp.h"
+#include "recurring_timer.h"
// load globas and give them their space to live
#include "globals.h"
@@ -35,18 +35,15 @@
deviceManagerClass *deviceManager;
xPLHandler *xPL;
xPLMessageQueueClass *xPLMessageQueue;
+
+static boost::asio::io_service* g_ioservice = nullptr;
-static boost::condition_variable g_exit_condition;
-static boost::mutex g_exit_mutex;
-static bool g_exit = false;
-
void handle_signal(int signal)
{
if (signal == SIGINT || signal == SIGTERM) {
- g_exit_mutex.lock();
- g_exit = true;
- g_exit_condition.notify_one();
- g_exit_mutex.unlock();
+ if (g_ioservice) {
+ g_ioservice->stop();
+ }
}
}
@@ -102,10 +99,13 @@
return -1;
}
}
+
+ boost::asio::io_service io;
+ g_ioservice = &io;
xPLMessageQueue = new xPLMessageQueueClass;
xPLCache = new xPLCacheClass;
- XHCPServer *xhcpServer = new XHCPServer();
+ XHCPServer *xhcpServer = new XHCPServer(io);
xPL = new xPLHandler( boost::asio::ip::host_name() ); //xPL->start();
deviceManager = new deviceManagerClass(xPLCache);
deviceManager->m_sigSendXplMessage.connect(boost::bind(&xPLMessageQueueClass::add, xPLMessageQueue, _1));
@@ -115,33 +115,22 @@
// force everyone to send their configuration so that we start up to date...
xPLMessage::namedValueList command_request; command_request.push_back( std::make_pair( "command", "request" ) );
xPL->sendBroadcastMessage( "config", "list", command_request );
+
+ RecurringTimer timer_listAllObjects(io, boost::posix_time::seconds(60), true);
+ timer_listAllObjects.setExpireHandler([](const boost::system::error_code& e) {
+ writeLog( "main: <tick>", logLevel::all );
+ writeLog( "xPLCache:\n" + xPLCache->listAllObjects(), logLevel::debug );
+ });
+
+ RecurringTimer timer_flushExpiredEntries(io, boost::posix_time::minutes(5), true);
+ timer_flushExpiredEntries.setExpireHandler([](const boost::system::error_code& e) {
+ writeLog( "main: flush cache", logLevel::all );
+ xPLCache->flushExpiredEntries(); // flush cache
+ });
- // main loop
- for( int count = 0;; ++count )
- {
- {
- boost::mutex::scoped_lock lock(g_exit_mutex);
- if (g_exit) break;
- boost::system_time const wait_until = boost::get_system_time() + boost::posix_time::seconds(10);
- g_exit_condition.timed_wait(lock, wait_until);
- if (g_exit) break;
- }
-
- writeLog( "main: run events", logLevel::all ); // run events
+ io.run();
+ g_ioservice = nullptr;
- if( 0 == count%6 )
- {
- writeLog( "main: <tick>", logLevel::all );
- writeLog( "xPLCache:\n" + xPLCache->listAllObjects(), logLevel::debug );
- }
- if( 30 == count ) // every 5 minutes
- {
- writeLog( "main: flush cache", logLevel::all );
- xPLCache->flushExpiredEntries(); // flush cache
- count = 0;
- }
- }
-
writeLog( "main: shutdown xPLHal", logLevel::all );
// clean up
Added: xPLHAL/branches/thomas_s_dev/src/recurring_timer.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/recurring_timer.cpp (rev 0)
+++ xPLHAL/branches/thomas_s_dev/src/recurring_timer.cpp 2011-12-31 18:18:39 UTC (rev 620)
@@ -0,0 +1,66 @@
+/*
+ xPLHAL implementation in C++
+ Copyright (C) 2009 by Christian Mayer - xpl at ChristianMayer dot de
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+#include "recurring_timer.h"
+#include <boost/bind.hpp>
+
+RecurringTimer::RecurringTimer(boost::asio::io_service& io_service,
+ const boost::asio::deadline_timer::duration_type& expiry_time,
+ bool startTimer)
+:m_timer(io_service, expiry_time)
+,m_delay(expiry_time)
+,m_running(false)
+,m_expireFunc(nullptr)
+{
+ if (startTimer) {
+ start();
+ }
+}
+
+RecurringTimer::~RecurringTimer()
+{
+ stop();
+}
+
+void RecurringTimer::setExpireHandler(void (*handler)(const boost::system::error_code& e))
+{
+ m_expireFunc = handler;
+}
+
+void RecurringTimer::start()
+{
+ m_running = true;
+ m_timer.async_wait(boost::bind(&RecurringTimer::onExpire, this, _1));
+}
+
+void RecurringTimer::stop()
+{
+ m_running = false;
+ m_timer.cancel();
+}
+
+void RecurringTimer::onExpire(const boost::system::error_code& e)
+{
+ if (m_running) {
+ m_timer.expires_at(m_timer.expires_at() + m_delay);
+ m_timer.async_wait(boost::bind(&RecurringTimer::onExpire, this, _1));
+ }
+ if (m_expireFunc) {
+ m_expireFunc(e);
+ }
+}
+
Added: xPLHAL/branches/thomas_s_dev/src/recurring_timer.h
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/recurring_timer.h (rev 0)
+++ xPLHAL/branches/thomas_s_dev/src/recurring_timer.h 2011-12-31 18:18:39 UTC (rev 620)
@@ -0,0 +1,41 @@
+#pragma once
+/*
+ xPLHAL implementation in C++
+ Copyright (C) 2009 by Christian Mayer - xpl at ChristianMayer dot de
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#include <boost/asio.hpp>
+
+class RecurringTimer
+{
+ public:
+ RecurringTimer(boost::asio::io_service& io_service, const boost::asio::deadline_timer::duration_type& expiry_time, bool startTimer = false);
+ ~RecurringTimer();
+
+ void setExpireHandler(void (*handler)(const boost::system::error_code& e));
+
+ void start();
+ void stop();
+
+ private:
+ void onExpire(const boost::system::error_code& e);
+
+ const boost::asio::deadline_timer::duration_type m_delay;
+ bool m_running;
+ boost::asio::deadline_timer m_timer;
+ void (*m_expireFunc)(const boost::system::error_code&);
+};
+
Modified: xPLHAL/branches/thomas_s_dev/src/xhcp.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xhcp.cpp 2011-12-31 18:16:57 UTC (rev 619)
+++ xPLHAL/branches/thomas_s_dev/src/xhcp.cpp 2011-12-31 18:18:39 UTC (rev 620)
@@ -23,27 +23,23 @@
using boost::asio::ip::tcp;
-XHCPServer::XHCPServer()
- : acceptor(io_service, tcp::endpoint(tcp::v4(), 3865)),
- m_stoprequested(false),
- m_thread(boost::bind(&XHCPServer::waitForConnection, this))
+XHCPServer::XHCPServer(boost::asio::io_service& io)
+:m_io(io)
+,m_acceptor(io, tcp::endpoint(tcp::v4(), 3865))
{
startAccept();
}
XHCPServer::~XHCPServer()
{
- m_stoprequested = true;
- acceptor.cancel();
- acceptor.close();
- io_service.stop();
- m_thread.join();
+ m_acceptor.cancel();
+ m_acceptor.close();
}
void XHCPServer::startAccept()
{
- socket_ptr sockPtr(new tcp::socket(io_service));
- acceptor.async_accept(*sockPtr, boost::bind(&XHCPServer::handleAccept, this, sockPtr));
+ socket_ptr sockPtr(new tcp::socket(m_io));
+ m_acceptor.async_accept(*sockPtr, boost::bind(&XHCPServer::handleAccept, this, sockPtr));
}
void XHCPServer::handleAccept(socket_ptr sockPtr)
@@ -52,19 +48,3 @@
XHCPThread* foo = new XHCPThread( sockPtr );
}
-void XHCPServer::waitForConnection( void )
-{
- writeLog( "XHCPServer::waitForConnection", logLevel::debug );
- io_service.run();
- /*
- while (!m_stoprequested)
- {
- socket_ptr sockPtr(new tcp::socket(io_service));
- writeLog("XHCPServer::waitForConnection in accept", logLevel::debug);
- acceptor.accept(*sockPtr);
- writeLog("XHCPServer::waitForConnection left accept", logLevel::debug);
-
- XHCPThread* foo = new XHCPThread( sockPtr );
- }
- */
-}
Modified: xPLHAL/branches/thomas_s_dev/src/xhcp.h
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xhcp.h 2011-12-31 18:16:57 UTC (rev 619)
+++ xPLHAL/branches/thomas_s_dev/src/xhcp.h 2011-12-31 18:18:39 UTC (rev 620)
@@ -18,7 +18,7 @@
*/
#include <boost/asio.hpp>
-#include <boost/thread.hpp>
+//#include <boost/thread.hpp>
#include "xplcache.h"
#include "xhcpthread.h"
@@ -29,18 +29,21 @@
*/
class XHCPServer
{
- boost::asio::io_service io_service;
- boost::asio::ip::tcp::tcp::acceptor acceptor;
- volatile bool m_stoprequested;
- boost::thread m_thread;
+ //volatile bool m_stoprequested;
+ //boost::thread m_thread;
public:
- XHCPServer();
+ XHCPServer(boost::asio::io_service& io);
~XHCPServer();
protected:
/** \brief Create a new XHCPThread for a new connection. */
- void waitForConnection( void );
+
+// void waitForConnection( void );
void handleAccept(socket_ptr sockPtr);
void startAccept();
+
+ private:
+ boost::asio::io_service& m_io;
+ boost::asio::ip::tcp::tcp::acceptor m_acceptor;
};
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tho...@us...> - 2011-12-31 18:17:03
|
Revision: 619
http://openautomation.svn.sourceforge.net/openautomation/?rev=619&view=rev
Author: thomas_s
Date: 2011-12-31 18:16:57 +0000 (Sat, 31 Dec 2011)
Log Message:
-----------
improved creation of xPLMessage objects
Modified Paths:
--------------
xPLHAL/branches/thomas_s_dev/src/devicemanager.cpp
xPLHAL/branches/thomas_s_dev/src/xplmessage.cpp
xPLHAL/branches/thomas_s_dev/src/xplmessage.h
Modified: xPLHAL/branches/thomas_s_dev/src/devicemanager.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/devicemanager.cpp 2011-12-31 14:53:57 UTC (rev 618)
+++ xPLHAL/branches/thomas_s_dev/src/devicemanager.cpp 2011-12-31 18:16:57 UTC (rev 619)
@@ -172,11 +172,10 @@
}
else {
// try to get at least the current config
- xPLMessage::namedValueList command_request; command_request.push_back( std::make_pair( "command", "request" ) );
xPLMessagePtr msg( new xPLMessage(xPL_MESSAGE_COMMAND,
source,
"config", "current",
- command_request) );
+ {{"command", "request"}}) );
m_sigSendXplMessage(msg);
}
}
@@ -227,11 +226,10 @@
// ask device for configuration (if haven't asked it before...)
if( !device.ConfigListSent ) {
- xPLMessage::namedValueList command_request; command_request.push_back( std::make_pair( "command", "request" ) );
xPLMessagePtr msg( new xPLMessage(xPL_MESSAGE_COMMAND,
source,
"config", "list",
- command_request) );
+ {{"command", "request"}}));
m_sigSendXplMessage(msg);
mDeviceMap[device.VDI].ConfigListSent = true;
}
@@ -302,11 +300,10 @@
mDeviceMap[device.VDI] = device;
// Throw it a config request anyway, see what turns up..
- xPLMessage::namedValueList command_request; command_request.push_back( std::make_pair( "command", "request" ) );
xPLMessagePtr msg( new xPLMessage(xPL_MESSAGE_COMMAND,
source,
"config", "list",
- command_request) );
+ {{"command", "request"}} ));
m_sigSendXplMessage(msg);
/* // that code below was from the VB - but we don't need it as processConfigList will
// itself send the config.current request...
Modified: xPLHAL/branches/thomas_s_dev/src/xplmessage.cpp
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xplmessage.cpp 2011-12-31 14:53:57 UTC (rev 618)
+++ xPLHAL/branches/thomas_s_dev/src/xplmessage.cpp 2011-12-31 18:16:57 UTC (rev 619)
@@ -57,11 +57,17 @@
bool xPLMessage::setTargetFromVDI(const std::string& target)
{
- size_t marker1 = target.find( "-" );
- size_t marker2 = target.find( "." );
- targetVendor = target.substr( 0, marker1 );
- targetDevice = target.substr( marker1+1, marker2 - (marker1+1) );
- targetInstance = target.substr( marker2+1 );
+ if (target == "*") {
+ isBroadcastMessage = true;
+ }
+ else {
+ isBroadcastMessage = false;
+ size_t marker1 = target.find( "-" );
+ size_t marker2 = target.find( "." );
+ targetVendor = target.substr( 0, marker1 );
+ targetDevice = target.substr( marker1+1, marker2 - (marker1+1) );
+ targetInstance = target.substr( marker2+1 );
+ }
return true;
}
@@ -110,6 +116,30 @@
return result;
}
+
+bool xPLMessage::operator==(const xPLMessage& right) const
+{
+ if (type != right.type) return false;
+ if (vendor != right.vendor) return false;
+ if (deviceID != right.deviceID) return false;
+ if (instanceID != right.instanceID) return false;
+ if (msgClass != right.msgClass) return false;
+ if (msgType != right.msgType) return false;
+ if (namedValues != right.namedValues) return false;
+ if (isBroadcastMessage != right.isBroadcastMessage) return false;
+ if (isGroupMessage != right.isGroupMessage) return false;
+ if (targetVendor != right.targetVendor) return false;
+ if (targetDevice != right.targetDevice) return false;
+ if (targetInstance != right.targetInstance) return false;
+ if (targetGroup != right.targetGroup) return false;
+ if (hopcount != right.hopcount) return false;
+ return true;
+}
+
+xPLMessage::operator std::string() const
+{
+ return printXPLMessage();
+}
std::ostream& operator<<(std::ostream& os, const xPLMessage& msg)
{
Modified: xPLHAL/branches/thomas_s_dev/src/xplmessage.h
===================================================================
--- xPLHAL/branches/thomas_s_dev/src/xplmessage.h 2011-12-31 14:53:57 UTC (rev 618)
+++ xPLHAL/branches/thomas_s_dev/src/xplmessage.h 2011-12-31 18:16:57 UTC (rev 619)
@@ -59,6 +59,9 @@
std::string targetGroup;
int hopcount;
+
+ xPLMessage() : hopcount(0), isBroadcastMessage(true), isGroupMessage(false)
+ {}
xPLMessage(
const xPL_MessageType _type,
@@ -69,7 +72,8 @@
const std::string& _msgType,
const namedValueList& _namedValues
) : type(_type), vendor(_vendor), deviceID(_deviceID), instanceID(_instanceID),
- msgClass(_msgClass), msgType(_msgType), namedValues(_namedValues)
+ msgClass(_msgClass), msgType(_msgType), namedValues(_namedValues),
+ hopcount(0), isBroadcastMessage(true), isGroupMessage(false)
{
}
@@ -79,7 +83,8 @@
const std::string& _msgClass,
const std::string& _msgType,
const namedValueList& _namedValues
- ) : type(_type), msgClass(_msgClass), msgType(_msgType), namedValues(_namedValues)
+ ) : type(_type), msgClass(_msgClass), msgType(_msgType), namedValues(_namedValues),
+ hopcount(0), isBroadcastMessage(true), isGroupMessage(false)
{
setSourceFromVDI(_vdi);
}
@@ -93,6 +98,9 @@
bool setTargetFromVDI(const std::string& vdi);
std::string getNamedValue(const std::string& tag) const;
+
+ operator std::string() const;
+ bool operator==(const xPLMessage& right) const;
};
typedef boost::shared_ptr<xPLMessage> xPLMessagePtr;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-31 14:54:04
|
Revision: 618
http://openautomation.svn.sourceforge.net/openautomation/?rev=618&view=rev
Author: mayerch
Date: 2011-12-31 14:53:57 +0000 (Sat, 31 Dec 2011)
Log Message:
-----------
Nicer format of the help string
Modified Paths:
--------------
tools/russconnectd/trunk/src/main.c
Modified: tools/russconnectd/trunk/src/main.c
===================================================================
--- tools/russconnectd/trunk/src/main.c 2011-12-30 21:35:32 UTC (rev 617)
+++ tools/russconnectd/trunk/src/main.c 2011-12-31 14:53:57 UTC (rev 618)
@@ -38,7 +38,16 @@
#define DEBUG 1
#define DAEMON_NAME "russconnectd"
-#define USAGESTRING "\n\t-d\tRun as daemon/No debug output\n\t-p <pidfile>\tPID-filename\n\t-i <ip:port>\tIP-Address:Port to send UDP-packets to russound\n\t-l <UDP-port>\tUDP port to listen on\n\t-a <KNX address>\tKNX start-address (see README)\n\t-z <number>\tNumber of Zones to support\n\t-u <eib url>\tURL to conatct eibd like localo:/tmp/eib or ip:192.168.0.101\n\t-s\t(Optional) send all values to KNX on startup of daemon\n\t-k 0x71\t(Optional) Keypad ID - defaults to 0x70 for CAx - use 0x71 for C5"
+#define USAGESTRING "\n"\
+ "\t-d Run as daemon/No debug output\n"\
+ "\t-p <pidfile> PID-filename\n"\
+ "\t-i <ip:port> IP-Address:Port to send UDP-packets to russound\n"\
+ "\t-l <UDP-port> UDP port to listen on\n"\
+ "\t-a <KNX address> KNX start-address (see README)\n"\
+ "\t-z <number> Number of Zones to support\n"\
+ "\t-u <eib url> URL to conatct eibd like localo:/tmp/eib or ip:192.168.0.101\n"\
+ "\t-s (Optional) send all values to KNX on startup of daemon\n"\
+ "\t-k 0x71 (Optional) Keypad ID - defaults to 0x70 for CAx - use 0x71 for C5\n"
#define NUM_THREADS 3
#define MAX_ZONES 31
#define RETRY_TIME 5
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-30 21:35:40
|
Revision: 617
http://openautomation.svn.sourceforge.net/openautomation/?rev=617&view=rev
Author: mayerch
Date: 2011-12-30 21:35:32 +0000 (Fri, 30 Dec 2011)
Log Message:
-----------
New release: 0.6.2
Modified Paths:
--------------
CometVisu/branches/release_0.6.2/visu/designs/alaska/basic.css
CometVisu/branches/release_0.6.2/visu/designs/alaska_slim/basic.css
CometVisu/branches/release_0.6.2/visu/lib/compatibility.js
CometVisu/branches/release_0.6.2/visu/visu_config_demo.xml
Added Paths:
-----------
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/LICENSE.txt
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/Tuffy.ttf
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/Tuffy_Bold.ttf
Removed Paths:
-------------
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/AUTHORS
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/COPYING
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/ChangeLog
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/License.txt
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/README
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/TODO
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/alaska_black_nocaps.ttf
CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/alaska_light_nocaps.ttf
CometVisu/branches/release_0.6.2/visu/designs/alaska_slim/fonts/
Property Changed:
----------------
CometVisu/branches/release_0.6.2/
Property changes on: CometVisu/branches/release_0.6.2
___________________________________________________________________
Added: svn:mergeinfo
+ /CometVisu/trunk:609,612
Modified: CometVisu/branches/release_0.6.2/visu/designs/alaska/basic.css
===================================================================
--- CometVisu/branches/release_0.6.2/visu/designs/alaska/basic.css 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/designs/alaska/basic.css 2011-12-30 21:35:32 UTC (rev 617)
@@ -1,10 +1,10 @@
@import "colors.css";
-@font-face { font-family: alaska; src:url(fonts/alaska_light_nocaps.ttf); }
-@font-face { font-family: alaska; font-weight: bold; src:url(fonts/alaska_black_nocaps.ttf); }
+@font-face { font-family: Tuffy; src:url(fonts/Tuffy.ttf); }
+@font-face { font-family: Tuffy; font-weight: bold; src:url(fonts/Tuffy_Bold.ttf); }
body
{
- font-family: alaska,sans-serif;
+ font-family: Tuffy,sans-serif;
font-size: 5.5mm;
overflow: hidden;
margin:0;
Deleted: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/AUTHORS
===================================================================
--- CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/AUTHORS 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/AUTHORS 2011-12-30 21:35:32 UTC (rev 617)
@@ -1,23 +0,0 @@
-AUTHORS
-
-Current Contributors (sorted alphabetically):
-
- - Caius 'kaio' Chance <caius.chance at gmail.com>
- Project Owner
- Red Hat, Inc.
-
- - Denis Jacquerye <moyogo at gmail.com>
- Project Contributor
-
- - Herbert Duerr <duerr at sun.com>
- Narrow Fonts Contributor
- Oracle, Inc.
-
-Previous Contributors
-
- - Steve Matteson
- Original Designer (support period expired)
- Ascender, Inc.
-
- - Mark Webbink <mwebbink AT redhat.com>
- Release coordinator, Red Hat Inc.
Deleted: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/COPYING
===================================================================
--- CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/COPYING 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/COPYING 2011-12-30 21:35:32 UTC (rev 617)
@@ -1,339 +0,0 @@
- GNU GENERAL PUBLIC LICENSE
- Version 2, June 1991
-
- Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
- 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
- Preamble
-
- The licenses for most software are designed to take away your
-freedom to share and change it. By contrast, the GNU General Public
-License is intended to guarantee your freedom to share and change free
-software--to make sure the software is free for all its users. This
-General Public License applies to most of the Free Software
-Foundation's software and to any other program whose authors commit to
-using it. (Some other Free Software Foundation software is covered by
-the GNU Lesser General Public License instead.) You can apply it to
-your programs, too.
-
- When we speak of free software, we are referring to freedom, not
-price. Our General Public Licenses are designed to make sure that you
-have the freedom to distribute copies of free software (and charge for
-this service if you wish), that you receive source code or can get it
-if you want it, that you can change the software or use pieces of it
-in new free programs; and that you know you can do these things.
-
- To protect your rights, we need to make restrictions that forbid
-anyone to deny you these rights or to ask you to surrender the rights.
-These restrictions translate to certain responsibilities for you if you
-distribute copies of the software, or if you modify it.
-
- For example, if you distribute copies of such a program, whether
-gratis or for a fee, you must give the recipients all the rights that
-you have. You must make sure that they, too, receive or can get the
-source code. And you must show them these terms so they know their
-rights.
-
- We protect your rights with two steps: (1) copyright the software, and
-(2) offer you this license which gives you legal permission to copy,
-distribute and/or modify the software.
-
- Also, for each author's protection and ours, we want to make certain
-that everyone understands that there is no warranty for this free
-software. If the software is modified by someone else and passed on, we
-want its recipients to know that what they have is not the original, so
-that any problems introduced by others will not reflect on the original
-authors' reputations.
-
- Finally, any free program is threatened constantly by software
-patents. We wish to avoid the danger that redistributors of a free
-program will individually obtain patent licenses, in effect making the
-program proprietary. To prevent this, we have made it clear that any
-patent must be licensed for everyone's free use or not licensed at all.
-
- The precise terms and conditions for copying, distribution and
-modification follow.
-
- GNU GENERAL PUBLIC LICENSE
- TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
-
- 0. This License applies to any program or other work which contains
-a notice placed by the copyright holder saying it may be distributed
-under the terms of this General Public License. The "Program", below,
-refers to any such program or work, and a "work based on the Program"
-means either the Program or any derivative work under copyright law:
-that is to say, a work containing the Program or a portion of it,
-either verbatim or with modifications and/or translated into another
-language. (Hereinafter, translation is included without limitation in
-the term "modification".) Each licensee is addressed as "you".
-
-Activities other than copying, distribution and modification are not
-covered by this License; they are outside its scope. The act of
-running the Program is not restricted, and the output from the Program
-is covered only if its contents constitute a work based on the
-Program (independent of having been made by running the Program).
-Whether that is true depends on what the Program does.
-
- 1. You may copy and distribute verbatim copies of the Program's
-source code as you receive it, in any medium, provided that you
-conspicuously and appropriately publish on each copy an appropriate
-copyright notice and disclaimer of warranty; keep intact all the
-notices that refer to this License and to the absence of any warranty;
-and give any other recipients of the Program a copy of this License
-along with the Program.
-
-You may charge a fee for the physical act of transferring a copy, and
-you may at your option offer warranty protection in exchange for a fee.
-
- 2. You may modify your copy or copies of the Program or any portion
-of it, thus forming a work based on the Program, and copy and
-distribute such modifications or work under the terms of Section 1
-above, provided that you also meet all of these conditions:
-
- a) You must cause the modified files to carry prominent notices
- stating that you changed the files and the date of any change.
-
- b) You must cause any work that you distribute or publish, that in
- whole or in part contains or is derived from the Program or any
- part thereof, to be licensed as a whole at no charge to all third
- parties under the terms of this License.
-
- c) If the modified program normally reads commands interactively
- when run, you must cause it, when started running for such
- interactive use in the most ordinary way, to print or display an
- announcement including an appropriate copyright notice and a
- notice that there is no warranty (or else, saying that you provide
- a warranty) and that users may redistribute the program under
- these conditions, and telling the user how to view a copy of this
- License. (Exception: if the Program itself is interactive but
- does not normally print such an announcement, your work based on
- the Program is not required to print an announcement.)
-
-These requirements apply to the modified work as a whole. If
-identifiable sections of that work are not derived from the Program,
-and can be reasonably considered independent and separate works in
-themselves, then this License, and its terms, do not apply to those
-sections when you distribute them as separate works. But when you
-distribute the same sections as part of a whole which is a work based
-on the Program, the distribution of the whole must be on the terms of
-this License, whose permissions for other licensees extend to the
-entire whole, and thus to each and every part regardless of who wrote it.
-
-Thus, it is not the intent of this section to claim rights or contest
-your rights to work written entirely by you; rather, the intent is to
-exercise the right to control the distribution of derivative or
-collective works based on the Program.
-
-In addition, mere aggregation of another work not based on the Program
-with the Program (or with a work based on the Program) on a volume of
-a storage or distribution medium does not bring the other work under
-the scope of this License.
-
- 3. You may copy and distribute the Program (or a work based on it,
-under Section 2) in object code or executable form under the terms of
-Sections 1 and 2 above provided that you also do one of the following:
-
- a) Accompany it with the complete corresponding machine-readable
- source code, which must be distributed under the terms of Sections
- 1 and 2 above on a medium customarily used for software interchange; or,
-
- b) Accompany it with a written offer, valid for at least three
- years, to give any third party, for a charge no more than your
- cost of physically performing source distribution, a complete
- machine-readable copy of the corresponding source code, to be
- distributed under the terms of Sections 1 and 2 above on a medium
- customarily used for software interchange; or,
-
- c) Accompany it with the information you received as to the offer
- to distribute corresponding source code. (This alternative is
- allowed only for noncommercial distribution and only if you
- received the program in object code or executable form with such
- an offer, in accord with Subsection b above.)
-
-The source code for a work means the preferred form of the work for
-making modifications to it. For an executable work, complete source
-code means all the source code for all modules it contains, plus any
-associated interface definition files, plus the scripts used to
-control compilation and installation of the executable. However, as a
-special exception, the source code distributed need not include
-anything that is normally distributed (in either source or binary
-form) with the major components (compiler, kernel, and so on) of the
-operating system on which the executable runs, unless that component
-itself accompanies the executable.
-
-If distribution of executable or object code is made by offering
-access to copy from a designated place, then offering equivalent
-access to copy the source code from the same place counts as
-distribution of the source code, even though third parties are not
-compelled to copy the source along with the object code.
-
- 4. You may not copy, modify, sublicense, or distribute the Program
-except as expressly provided under this License. Any attempt
-otherwise to copy, modify, sublicense or distribute the Program is
-void, and will automatically terminate your rights under this License.
-However, parties who have received copies, or rights, from you under
-this License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
- 5. You are not required to accept this License, since you have not
-signed it. However, nothing else grants you permission to modify or
-distribute the Program or its derivative works. These actions are
-prohibited by law if you do not accept this License. Therefore, by
-modifying or distributing the Program (or any work based on the
-Program), you indicate your acceptance of this License to do so, and
-all its terms and conditions for copying, distributing or modifying
-the Program or works based on it.
-
- 6. Each time you redistribute the Program (or any work based on the
-Program), the recipient automatically receives a license from the
-original licensor to copy, distribute or modify the Program subject to
-these terms and conditions. You may not impose any further
-restrictions on the recipients' exercise of the rights granted herein.
-You are not responsible for enforcing compliance by third parties to
-this License.
-
- 7. If, as a consequence of a court judgment or allegation of patent
-infringement or for any other reason (not limited to patent issues),
-conditions are imposed on you (whether by court order, agreement or
-otherwise) that contradict the conditions of this License, they do not
-excuse you from the conditions of this License. If you cannot
-distribute so as to satisfy simultaneously your obligations under this
-License and any other pertinent obligations, then as a consequence you
-may not distribute the Program at all. For example, if a patent
-license would not permit royalty-free redistribution of the Program by
-all those who receive copies directly or indirectly through you, then
-the only way you could satisfy both it and this License would be to
-refrain entirely from distribution of the Program.
-
-If any portion of this section is held invalid or unenforceable under
-any particular circumstance, the balance of the section is intended to
-apply and the section as a whole is intended to apply in other
-circumstances.
-
-It is not the purpose of this section to induce you to infringe any
-patents or other property right claims or to contest validity of any
-such claims; this section has the sole purpose of protecting the
-integrity of the free software distribution system, which is
-implemented by public license practices. Many people have made
-generous contributions to the wide range of software distributed
-through that system in reliance on consistent application of that
-system; it is up to the author/donor to decide if he or she is willing
-to distribute software through any other system and a licensee cannot
-impose that choice.
-
-This section is intended to make thoroughly clear what is believed to
-be a consequence of the rest of this License.
-
- 8. If the distribution and/or use of the Program is restricted in
-certain countries either by patents or by copyrighted interfaces, the
-original copyright holder who places the Program under this License
-may add an explicit geographical distribution limitation excluding
-those countries, so that distribution is permitted only in or among
-countries not thus excluded. In such case, this License incorporates
-the limitation as if written in the body of this License.
-
- 9. The Free Software Foundation may publish revised and/or new versions
-of the General Public License from time to time. Such new versions will
-be similar in spirit to the present version, but may differ in detail to
-address new problems or concerns.
-
-Each version is given a distinguishing version number. If the Program
-specifies a version number of this License which applies to it and "any
-later version", you have the option of following the terms and conditions
-either of that version or of any later version published by the Free
-Software Foundation. If the Program does not specify a version number of
-this License, you may choose any version ever published by the Free Software
-Foundation.
-
- 10. If you wish to incorporate parts of the Program into other free
-programs whose distribution conditions are different, write to the author
-to ask for permission. For software which is copyrighted by the Free
-Software Foundation, write to the Free Software Foundation; we sometimes
-make exceptions for this. Our decision will be guided by the two goals
-of preserving the free status of all derivatives of our free software and
-of promoting the sharing and reuse of software generally.
-
- NO WARRANTY
-
- 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
-FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
-OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
-PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
-OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
-TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
-PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
-REPAIR OR CORRECTION.
-
- 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
-WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
-REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
-INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
-OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
-TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
-YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
-PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
-POSSIBILITY OF SUCH DAMAGES.
-
- END OF TERMS AND CONDITIONS
-
- How to Apply These Terms to Your New Programs
-
- If you develop a new program, and you want it to be of the greatest
-possible use to the public, the best way to achieve this is to make it
-free software which everyone can redistribute and change under these terms.
-
- To do so, attach the following notices to the program. It is safest
-to attach them to the start of each source file to most effectively
-convey the exclusion of warranty; and each file should have at least
-the "copyright" line and a pointer to where the full notice is found.
-
- <one line to give the program's name and a brief idea of what it does.>
- Copyright (C) <year> <name of author>
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License along
- with this program; if not, write to the Free Software Foundation, Inc.,
- 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-
-Also add information on how to contact you by electronic and paper mail.
-
-If the program is interactive, make it output a short notice like this
-when it starts in an interactive mode:
-
- Gnomovision version 69, Copyright (C) year name of author
- Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
- This is free software, and you are welcome to redistribute it
- under certain conditions; type `show c' for details.
-
-The hypothetical commands `show w' and `show c' should show the appropriate
-parts of the General Public License. Of course, the commands you use may
-be called something other than `show w' and `show c'; they could even be
-mouse-clicks or menu items--whatever suits your program.
-
-You should also get your employer (if you work as a programmer) or your
-school, if any, to sign a "copyright disclaimer" for the program, if
-necessary. Here is a sample; alter the names:
-
- Yoyodyne, Inc., hereby disclaims all copyright interest in the program
- `Gnomovision' (which makes passes at compilers) written by James Hacker.
-
- <signature of Ty Coon>, 1 April 1989
- Ty Coon, President of Vice
-
-This General Public License does not permit incorporating your program into
-proprietary programs. If your program is a subroutine library, you may
-consider it more useful to permit linking proprietary applications with the
-library. If this is what you want to do, use the GNU Lesser General
-Public License instead of this License.
Deleted: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/ChangeLog
===================================================================
--- CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/ChangeLog 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/ChangeLog 2011-12-30 21:35:32 UTC (rev 617)
@@ -1,224 +0,0 @@
-* Wed Jul 21 2010 Pravin Satpute <psa...@re...>
-- Update for New Release 1.06
-- Added New Family Narrow (Contribution from Herbert Duerr <her...@or...>)
-- updated version of fonts
-
-* Mon 10 May 2010 Caius 'kaio' Chance <me at kaio.net>
-- Fixed Romanian glyphs, U+021A, 021B, 0218, 0219, 0162, 0163, 015E, 015F,
- 2010, 2011. (rhbz#440992)
-- Fixed height of arrows U+2190, 2192, 2194. (Issue #2)
-
-* Thu 06 May 2010 Caius 'kaio' Chance <me at kaio.net>
-- Cleaned up points and auto-instructed hinting of 'u', 'v', 'w', 'y'.
-(rhbz#463036)
-- Created the first project icon. (Issue #5)
-
-* Wed May 05 2010 Caius 'kaio' Chance <k at kaio.net>
-- Incorrect cent sign glyph (U+00A2) in Sans and Mono
-style in Liberation fonts. (rhbz#474522)
-
-* Wed 28 Apr 2010 Caius 'kaio' Chance <me at kaio.net>
-- rhbz#510174: Corrected version number of all SFD files.
-- Corrected license exceptions to GPLv2.
-- Updated README file.
-
-* Tue 27 Apr 2010 Caius 'kaio' Chance <me at kaio.net>
-- Renamed Narrow Fonts.
-- Updated list of contributors.
-- Released version 1.05.3.
-
-* Thu 22 Apr 2010 Herbert Duerr <duerr at sun.com>
-- Contributed Liberation Sans Narrow Fonts.
-
-* Fri 12 Mar 2010 Caius 'kaio' Chance <me at kaio.me>
-- Migrated to Google Code.
-- Updated AUTHORS.
-- Upgraded license to GPLv3+exceptions.
-
-* Sun 27 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Fixed ttf pack preparation error.
-
-* Tue 21 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Fixed 'wrongly encoded glyphs after U+10000' (rhbz#525498),
- provided by Denis Jacquerye <moyogo at gmail.com>.
-
-* Tue 21 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Fixed fontforge script sfd2ttf.pe.
-- Include traditional kern table for Sans and Serif.
-
-* Tue 14 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Generated TTFs with tradition kern table, with fontforge ver 20090408.
-- Added make target alias dist-src as dist-sfd.
-
-* Mon 13 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Updated for generation of traditional kern table via scripts.
-
-* Mon 06 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Reconverted SFDs from original TTFs with traditional kern table.
-- Updated "clean" target in Makefile.
-
-* Tue 30 Jun 2009 Caius 'kaio' Chance <me at kaio.me>
-- Reconverted SFDs from original TTFs with traditional kern table.
-- Updated "clean" target in Makefile.
-
-* Tue 30 Jun 2009 Caius 'kaio' Chance <me at kaio.me>
-- Generated cleaner SFD from original TTFs.
-- Include Makefile in sources tarball.
-
-* Wed 24 Jun 2009 Caius 'kaio' Chance <me at kaio.me>
-- Makefile: pack SFD files as source tarball.
-- Makefile: pack TTF files as ttf packs.
-- Tidy up repository.
-- Updated documents.
-
-* Mon 12 Jan 2009 Caius Chance <cchance at redhat.com>
-- Fixed copyright holder name typo for Sans Regular font (rhbz#479521).
-
-* Tue 09 Dec 2008 Caius Chance <cchance at redhat.com>
-- Changed cent sign glyph (U+00A2) to be coressed in Sans and Mono
- (rhbz#474522).
-
-* Wed 03 Dec 2008 Caius Chance <cchance at redhat.com>
-- Started 1.04.93.devel.
-- Fixed blurriness of U+03BC for Sans Regular font (rhbz#473481).
-- Fixed src tarball mis-inclusion of dist files in Makefile.
-
-* Fri 28 Nov 2008 Caius Chance <cchance at redhat.com>
-- Corrected version number in Makefile.
-- Fixed make target of source tarball.
-- Uploaded 1.04.92 source tarball to release area.
-
-* Wed 15 Oct 2008 Caius Chance <cchance at redhat.com>
-- Fixed blurred 'u' and 'W' for Sans Bold font (rhbz#463036).
-- Released as version 1.04.92
-
-* Wed 17 Sep 2008 Caius Chance <cchance at redhat.com>
-- Fixed missing hinting instructions for all Mono fonts (rhbz#460090).
-- Fixed missing hinting instructions for all Sans fonts (rhbz#460090).
-- Fixed missing hinting instructions for all Serif fonts (rhbz#460090).
-- Released as version 1.04.91
-
-* Tue 09 Sep 2008 Caius Chance <cchance at redhat.com>
-- Backed up all released files in ./dist directory.
-
-* Fri 05 Sep 2008 Caius Chance <cchance at redhat.com>
-- Fixed incorrect glyph points and missing hinting instructions for:
- Mono Bold Italic (up to U+2012) (rhbz#460090).
-
-* Mon 25 Aug 2008 Caius Chance <cchance at redhat.com>
-- Fixed incorrect glyph points and missing hinting instructions for:
- U+0079, U+03BC, U+0431, U+2010..2012, U+1114117 (rhbz#458592).
-- Released as version 1.04.90.
-
-* Thu 13 Jul 2008 Caius Chance <cchance at redhat.com>
-- Released as version 1.04.
-
-* Thu 12 Jun 2008 Caius Chance <cchance at redhat.com>
-- Released as version 1.04.beta2 (1.03.99).
-- Added ZIP package building for non-tar users.
-- rhbz#440992:
- - Created Romanian "T/t/S/s with comma below" (U+0218..021B) on all fonts.
- - Fixed "T/s with cedilla below" (U+0162/0163) on all fonts.
- - Created "Hyphen" and "Non-Breaking Hyphen" (U+2010..2011) on all fonts.
-
-* Wed 11 Jun 2008 Caius Chance <cchance at redhat.com>
-- Added last Version 1.03 from original manufacturer.
-- Renamed directory 'archive' to 'sandbox'.
-- Added directory description in hosting home directory.
-- Created ZIP packages for Version 1.03 and 1.04.beta.
-
-* Tue 04 Jun 2008 Caius Chance <cchance at redhat.com>
-- rhbz#440992:
- - Created "Hyphen" and "Non-Breaking Hyphen" (U+2010..2011) on Sans Regular.
-
-* Mon 03 Jun 2008 Caius Chance <cchance at redhat.com>
-- rhbz#440992:
- - Created Romanian "T/t/S/s with comma below" (U+0218..021B) on Sans Regular.
- - Fixed "T/s with cedilla below" (U+0162/0163) on Sans Regular.
-
-* Fri 30 May 2008 Caius Chance <cchance at redhat.com>
-- Release Version 1.04.beta (liberation-fonts-1_04_beta).
-
-* Thu 29 May 2008 Caius Chance <cchance at redhat.com>
-- Correct SFD version numbers in "TTF Info" categor for correct version
- number during export to TTFs.
-
-* Wed 28 May 2008 Caius Chance <cchance at redhat.com>
-- Reencoded with "Glyph Order" by FontForge.
-- Corrected font name for all Regular fonts.
-- Generated TTFs (experimantal, in "archive") with old stle kern and dummy
- DSIG table.
-- Updated README in 1.04b TTFs (experimental, in "archive").
-
-* Tue 27 May 2008 Caius Chance <cchance at redhat.com>
-- Fixed Unicode name mis-mapping of Sans and Serif TTF files.
-- Regenerate SFD files from Unicode name mis-mapping fixed Sans and Serif TTF
- files.
-
-* Mon 26 May 2008 Caius Chance <cchance at redhat.com>
-- Fixed Unicode name mis-mapping of Mono TTF files.
-- Regenerate SFD files from Unicode name mis-mapping fixed Mono TTF files.
-==========
-- Applied following patches submitted by Nicolas Spalinger
- <nicolas_spalinger sil org>:
- - We-need-versioned-tarballs.
- - Add-ignore-file-so-the-VCS-does-not-track-the-folder.
- - Adjust-path-for-various-Makefile-targets-subfolders.
- - Fix-versionning-mismatch-in-the-binary-font-metadata.
- - Add-some-description-and-extra-lines-to-the-build-ta.
- - Reword-and-restructure-maintainers-recommendations.
- - Some-rewording-of-the-readme-file.
-==========
-
-* Thu May 22 2008 Caius Chance <cchance at redhat.com>
-- Added latest (1.03) TTF files from Ascender. (in 'archive')
-
-* Fri May 16 2008 Caius Chance <cchance at redhat.com>
-- Change source tree as 'trunk', 'tags', 'branches'.
-==========
-- Applied following patches submitted by Nicolas Spalinger
- <nicolas_spalinger sil org>:
- - Add-more-information-about-the-upstream-designer.
- - Minor-typo-and-layout-fixes.
- - Adjust-fontforge-path-with-env-as-a-source-build.
-==========
-
-* Wed May 14 2008 Caius Chance <cchance at redhat.com>
-- Renamed target 'ttf' to 'build'.
-- Removed 'Re-Package' chapter from README and refine contents.
-- Changed AUTHORS contents.
-- Created maintainer documentation MAINTAINER.
-
-* Tue May 06 2008 Caius Chance <cchance at redhat.com>
-- Refined clean target.
-- Removed TTFs from git.
-
-* Fri May 02 2008 Caius Chance <cchance at redhat.com>
-- Imported into fedorahosted.org repository and be hosted.
- https://fedorahosted.org/liberation-fonts/
-- Modified source root directory name definition in Makefile.
-- Created 'dist' target for binary TTF tarball and 'src' for source tarball.
-- Corrected Regular fonts filenames.
-- Added TTF -> SFD make target.
-
-* Thu May 01 2008 Caius Chance <cchance at redhat.com>
-- Converted previous TTF files into SFD files to be open source.
-- Created fontforge SFD -> TTF scripts.
-- Created Makefile.
-- Added documentations: AUTHORS, ChangeLog, README.
-
-* Thu Apr 10 2008 Caius Chance <cchance at redhat.com>
-- Fixed exchanged and incomplete glyphs (from Ascender).
-- Repacked source tarball.
-- Released version 1.03.
-
-* Tue Mar 25 2008 Caius Chance <cchance at redhat.com>
-- Fixed alignment mismatch of dot accents (from Ascender).
-- Released version 1.02.
-
-* Mon Jan 14 2008 Caius Chance <cchance at redhat.com>
-- Updated new source tarball from Ascender.
-- Released version 1.0.
-
-* Thu Jun 14 2007 Caius Chance <cchance at redhat.com>
-- Updated new source tarball from Ascender.
Copied: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/LICENSE.txt (from rev 612, CometVisu/trunk/visu/designs/alaska/fonts/LICENSE.txt)
===================================================================
--- CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/LICENSE.txt (rev 0)
+++ CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/LICENSE.txt 2011-12-30 21:35:32 UTC (rev 617)
@@ -0,0 +1,5 @@
+I have placed these fonts in the Public Domain. This is all 100% my
+own work. Usage is totally unrestricted. If you want to make
+derivative works for any purpose, please go ahead.
+
+-Thatcher Ulrich <tu...@tu...> http://tulrich.com
Deleted: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/License.txt
===================================================================
--- CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/License.txt 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/License.txt 2011-12-30 21:35:32 UTC (rev 617)
@@ -1,19 +0,0 @@
-LICENSE AGREEMENT AND LIMITED PRODUCT WARRANTY
-LIBERATION FONT SOFTWARE
-
-This agreement governs the use of the Software and any updates to the Software, regardless of the delivery mechanism. Subject to the following terms, Red Hat, Inc. ("Red Hat") grants to the user ("Client") a license to this work pursuant to the GNU General Public License v.2 with the exceptions set forth below and such other terms as are set forth in this End User License Agreement.
-
- 1. The Software and License Exception. LIBERATION font software (the "Software") consists of TrueType-OpenType formatted font software for rendering LIBERATION typefaces in sans-serif, serif, and monospaced character styles. You are licensed to use, modify, copy, and distribute the Software pursuant to the GNU General Public License v.2 with the following exceptions:
-
- (a) As a special exception, if you create a document which uses this font, and embed this font or unaltered portions of this font into the document, this font does not by itself cause the resulting document to be covered by the GNU General Public License. This exception does not however invalidate any other reasons why the document might be covered by the GNU General Public License. If you modify this font, you may extend this exception to your version of the font, but you are not obligated to do so. If you do not wish to do so, delete this exception statement from your version.
-
- (b) As a further exception, any distribution of the object code of the Software in a physical product must provide you the right to access and modify the source code for the Software and to reinstall that modified version of the Software in object code form on the same physical product on which you received it.
-
- 2. Intellectual Property Rights. The Software and each of its components, including the source code, documentation, appearance, structure and organization are owned by Red Hat and others and are protected under copyright and other laws. Title to the Software and any component, or to any copy, modification, or merged portion shall remain with the aforementioned, subject to the applicable license. The "LIBERATION" trademark is a trademark of Red Hat, Inc. in the U.S. and other countries. This agreement does not permit Client to distribute modified versions of the Software using Red Hat's trademarks. If Client makes a redistribution of a modified version of the Software, then Client must modify the files names to remove any reference to the Red Hat trademarks and must not use the Red Hat trademarks in any way to reference or promote the modified Software.
-
- 3. Limited Warranty. To the maximum extent permitted under applicable law, the Software is provided and licensed "as is" without warranty of any kind, expressed or implied, including the implied warranties of merchantability, non-infringement or fitness for a particular purpose. Red Hat does not warrant that the functions contained in the Software will meet Client's requirements or that the operation of the Software will be entirely error free or appear precisely as described in the accompanying documentation.
-
- 4. Limitation of Remedies and Liability. To the maximum extent permitted by applicable law, Red Hat or any Red Hat authorized dealer will not be liable to Client for any incidental or consequential damages, including lost profits or lost savings arising out of the use or inability to use the Software, even if Red Hat or such dealer has been advised of the possibility of such damages.
-
- 5. General. If any provision of this agreement is held to be unenforceable, that shall not affect the enforceability of the remaining provisions. This agreement shall be governed by the laws of the State of North Carolina and of the United States, without regard to any conflict of laws provisions, except that the United Nations Convention on the International Sale of Goods shall not apply.
-Copyright © 2007 Red Hat, Inc. All rights reserved. LIBERATION is a trademark of Red Hat, Inc.
Deleted: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/README
===================================================================
--- CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/README 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/README 2011-12-30 21:35:32 UTC (rev 617)
@@ -1,82 +0,0 @@
- 1. What's this?
- =================
-
- The Liberation Fonts is font collection which aims to provide document
- layout compatibility as usage of Times New Roman, Arial, Courier New.
-
-
- 2. Requirements
- =================
-
- * fontforge is installed.
- (http://fontforge.sourceforge.net)
-
-
- 3. Install
- ============
-
- 3.1 Decompress tarball
-
- You can extract the files by following command:
-
- $ tar zxvf liberation-fonts-[VERSION].tar.gz
-
- 3.2 Build from the source
-
- Change into directory liberation-fonts-[VERSION]/ and build from sources by
- following commands:
-
- $ cd liberation-fonts-[VERSION]
- $ make
-
- The built font files will be available in 'build' directory.
-
- 3.3 Install to system
-
- For Fedora, you could manually install the fonts by copying the TTFs to
- ~/.fonts for user wide usage, or to /usr/share/fonts/truetype/liberation
- for system-wide availability. Then, run "fc-cache" to let that cached.
-
- For other distributions, please check out corresponding documentation.
-
-
- 4. Usage
- ==========
-
- Simply select preferred liberation font in applications and start using.
-
-
- 5. License
- ============
-
- This font set had been released under GNU Public License version 2
- ("GPLv2") with exceptions.
-
- Please read file "COPYING" for GPLv2 license.
-
- Please read file "License.txt" for details of exceptions.
-
-
- 6. For Maintainers
- ====================
-
- Before packaging a new release based on a new source tarball, you have to
- update the version suffix in the Makefile:
-
- VER = [VERSION]
-
- Make sure that the defined version corresponds to the font software metadata
- which you can check with ftinfo/otfinfo or fontforge itself. It is highly
- recommended that file 'ChangeLog' is updated to reflect changes.
-
- Create a tarball with the following command:
-
- $ make dist
-
- The new versioned tarball will be available in the dist/ folder as
- 'liberation-fonts-[NEW_VERSION].tar.gz'.
-
- 7. Credits
- ============
-
- Please read file "AUTHORS" for list of contributors.
Deleted: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/TODO
===================================================================
--- CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/TODO 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/TODO 2011-12-30 21:35:32 UTC (rev 617)
@@ -1,14 +0,0 @@
-Here are todo for next release
-
-1) resolving bug related with hinting
- - https://bugzilla.redhat.com/show_bug.cgi?id=606217
- - https://bugzilla.redhat.com/show_bug.cgi?id=591556
-2) shape improvement
- - https://bugzilla.redhat.com/show_bug.cgi?id=591559
- - https://bugzilla.redhat.com/show_bug.cgi?id=487581
-3) Ascent Descent Values Improvement
- - using absolute values instead of relative values in OS/2 table
-4) RFE: Add Greek Polytonic support to Liberation fonts
- - need some volunteer to add these shapes
- - https://bugzilla.redhat.com/show_bug.cgi?id=473842
-
Copied: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/Tuffy.ttf (from rev 612, CometVisu/trunk/visu/designs/alaska/fonts/Tuffy.ttf)
===================================================================
(Binary files differ)
Copied: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/Tuffy_Bold.ttf (from rev 612, CometVisu/trunk/visu/designs/alaska/fonts/Tuffy_Bold.ttf)
===================================================================
(Binary files differ)
Deleted: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/alaska_black_nocaps.ttf
===================================================================
(Binary files differ)
Deleted: CometVisu/branches/release_0.6.2/visu/designs/alaska/fonts/alaska_light_nocaps.ttf
===================================================================
(Binary files differ)
Modified: CometVisu/branches/release_0.6.2/visu/designs/alaska_slim/basic.css
===================================================================
--- CometVisu/branches/release_0.6.2/visu/designs/alaska_slim/basic.css 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/designs/alaska_slim/basic.css 2011-12-30 21:35:32 UTC (rev 617)
@@ -1,10 +1,10 @@
@import "colors.css";
-@font-face { font-family: alaska; src:url(fonts/alaska_light_nocaps.ttf); }
-@font-face { font-family: alaska; font-weight: bold; src:url(fonts/alaska_black_nocaps.ttf); }
+@font-face { font-family: Tuffy; src:url(../alaska/fonts/Tuffy.ttf); }
+@font-face { font-family: Tuffy; font-weight: bold; src:url(../alaska/fonts/Tuffy_Bold.ttf); }
body
{
- font-family: alaska,sans-serif;
+ font-family: Tuffy,sans-serif;
font-size: 5mm;
overflow: hidden;
margin:0;
Modified: CometVisu/branches/release_0.6.2/visu/lib/compatibility.js
===================================================================
--- CometVisu/branches/release_0.6.2/visu/lib/compatibility.js 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/lib/compatibility.js 2011-12-30 21:35:32 UTC (rev 617)
@@ -48,7 +48,7 @@
min: match[6] || 0,
precision: match[8],
code: match[9] || '%',
- negative: parseInt(arguments[convCount]) < 0 ? true : false,
+ negative: parseFloat(arguments[convCount]) < 0 ? true : false,
argument: String(arguments[convCount])
};
}
Modified: CometVisu/branches/release_0.6.2/visu/visu_config_demo.xml
===================================================================
--- CometVisu/branches/release_0.6.2/visu/visu_config_demo.xml 2011-12-30 21:08:08 UTC (rev 616)
+++ CometVisu/branches/release_0.6.2/visu/visu_config_demo.xml 2011-12-30 21:35:32 UTC (rev 617)
@@ -77,7 +77,7 @@
]]></status>
<status type="html"><![CDATA[
- <a href="check_config.php">Check Config</a>
- <div style="float:right;padding-right:0.5em">Version: 0.6.1</div>
+ <div style="float:right;padding-right:0.5em">Version: 0.6.2</div>
]]></status>
</statusbar>
</meta>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-30 21:08:14
|
Revision: 616
http://openautomation.svn.sourceforge.net/openautomation/?rev=616&view=rev
Author: mayerch
Date: 2011-12-30 21:08:08 +0000 (Fri, 30 Dec 2011)
Log Message:
-----------
Creating release branch 0.6.2
Added Paths:
-----------
CometVisu/branches/release_0.6.2/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-29 01:50:49
|
Revision: 615
http://openautomation.svn.sourceforge.net/openautomation/?rev=615&view=rev
Author: makki1
Date: 2011-12-29 01:50:42 +0000 (Thu, 29 Dec 2011)
Log Message:
-----------
WireGate-Plugin: Template for sending eMail by SMTP with auth
Modified Paths:
--------------
wiregate/plugin/generic/VPN-User-by-GA
Added Paths:
-----------
wiregate/plugin/generic/SMTP-eMail.pl
Added: wiregate/plugin/generic/SMTP-eMail.pl
===================================================================
--- wiregate/plugin/generic/SMTP-eMail.pl (rev 0)
+++ wiregate/plugin/generic/SMTP-eMail.pl 2011-12-29 01:50:42 UTC (rev 615)
@@ -0,0 +1,55 @@
+# Demo-Plugin zum eMail-Versand - einfache Version mit Text-only
+# das macht nichts sinnvolles, sendet jede Stunde ein eMail,
+# soll nur als Vorlage dienen
+
+# Aufbau moeglichst so, dass man unterhalb der Definitionen nichts aendern muss!
+
+my $hostname = `hostname`;
+
+##################
+### DEFINITION ###
+##################
+
+my $Empfaenger = 'me...@do...'; # Anpassen, mehrere mit ,
+
+my $Absender = 'WireGate <ab...@gm...>'; # unbedingt anpassen, die Absenderadresse sollte gültig sein um Probleme zu vermeiden
+my $Betreff = "eMail von $hostname";
+my $text = "email-Body";
+my $username = 'ab...@gm...'; #Anpassen! Username fuer SMTP-Server
+my $password = "meinpasswort"; #Anpassen! Passwort fuer SMTP-Server
+my $mailserver='mail.gmx.net'; # SMTP-Relay: das muss natuerlich angepasst werden!
+$plugin_info{$plugname.'_cycle'} = 3600;
+
+#######################
+### ENDE DEFINITION ###
+#######################
+
+use Net::SMTP;
+use MIME::Base64;
+
+my $smtp = Net::SMTP->new($mailserver, Timeout => 5, Debug =>1) or return "Fehler beim verbinden zu $mailserver $!";
+my $ret .= ' auth:'. $smtp->auth($username,$password);
+$smtp->status() < 5
+or do {
+ # Die smtp->auth Methode schlaegt fehl, also dann so
+ $smtp->datasend("AUTH LOGIN\n") or return 'auth login problem';
+ $smtp->response();
+ $smtp->datasend(encode_base64( $username ) ) or return "username $username cannot be encoded or wrong";
+ $smtp->response();
+ $smtp->datasend(encode_base64( $password ) ) or return "password $password cannot be encoded or wrong";
+ $smtp->response();
+};
+$ret .= 'status:' . $smtp->status();
+$ret .= ' send:'. $smtp->mail($Absender);
+$ret .= ' rcpt:'. $smtp->to($Empfaenger);
+$ret .= $smtp->data();
+$ret .= $smtp->datasend("To: $Empfaenger\n"); # Empfänger (Header)
+$ret .= $smtp->datasend("Subject: $Betreff\n"); # Betreff
+$ret .= $smtp->datasend("\n");
+$ret .= $smtp->datasend("$text\n");
+$ret .= $smtp->dataend();
+$ret .= $smtp->quit;
+
+# FIXME: check if we succeeded
+return;
+
Modified: wiregate/plugin/generic/VPN-User-by-GA
===================================================================
--- wiregate/plugin/generic/VPN-User-by-GA 2011-12-28 18:37:09 UTC (rev 614)
+++ wiregate/plugin/generic/VPN-User-by-GA 2011-12-29 01:50:42 UTC (rev 615)
@@ -70,15 +70,15 @@
if (! -e '/etc/openvpn/connect.sh' or ! -e '/etc/openvpn/disconnect.sh') {
open(OUT, ">/etc/openvpn/connect.sh");
print OUT "#!/bin/bash\n\nif [ -e /etc/openvpn/servers/\$common_name.disabled ]; then\n";
- print OUT "\tlogger -t VPN 'refused disabled VPN-user \$common_name from \$trusted_ip'\n";
+ print OUT "\tlogger -t VPN \"refused disabled VPN-user \$common_name from \$trusted_ip\"\n";
print OUT "\texit 1\nelse \n";
- print OUT "\tlogger -t VPN '\$common_name logged in from \$trusted_ip (\$ifconfig_pool_remote_ip)'\n";
+ print OUT "\tlogger -t VPN \"\$common_name logged in from \$trusted_ip (\$ifconfig_pool_remote_ip)\"\n";
print OUT "\tVPNGA=`grep \"^\$common_name=\" /etc/openvpn/servers/VPNGA_MAP | cut -d'=' -f 2`\n";
print OUT "\tgroupswrite local:/tmp/eib \$VPNGA 1\nfi\nexit 0\n";
close(OUT);
open(OUT, ">/etc/openvpn/disconnect.sh");
print OUT "#!/bin/bash\n\n";
- print OUT "logger -t VPN '\$common_name logged out from \$trusted_ip (\$ifconfig_pool_remote_ip) T: \$time_duration S: \$bytes_sent R: \$bytes_received'\n";
+ print OUT "logger -t VPN \"\$common_name logged out from \$trusted_ip (\$ifconfig_pool_remote_ip) T: \$time_duration S: \$bytes_sent R: \$bytes_received\"\n";
print OUT "VPNGA=`grep \"^\$common_name\" /etc/openvpn/servers/VPNGA_MAP | cut -d'=' -f 2`\n";
print OUT "groupswrite local:/tmp/eib \$VPNGA 0\n";
close(OUT);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-28 18:37:18
|
Revision: 614
http://openautomation.svn.sourceforge.net/openautomation/?rev=614&view=rev
Author: makki1
Date: 2011-12-28 18:37:09 +0000 (Wed, 28 Dec 2011)
Log Message:
-----------
russconnectd: Fix for setting Bass/Treble and add device restart-event on zone-polling to wakeup C3(?), prepare release 0.21
Modified Paths:
--------------
tools/russconnectd/trunk/configure.ac
tools/russconnectd/trunk/debian/changelog
tools/russconnectd/trunk/debian/files
tools/russconnectd/trunk/src/main.c
Modified: tools/russconnectd/trunk/configure.ac
===================================================================
--- tools/russconnectd/trunk/configure.ac 2011-12-28 00:15:30 UTC (rev 613)
+++ tools/russconnectd/trunk/configure.ac 2011-12-28 18:37:09 UTC (rev 614)
@@ -1,7 +1,7 @@
dnl Process this file with autoconf to produce a configure script.
dnl Created by Anjuta application wizard.
-AC_INIT(russconnectd, 0.2, de...@wi..., , http://openautomation.sourceforge.net)
+AC_INIT(russconnectd, 0.21, de...@wi..., , http://openautomation.sourceforge.net)
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION)
Modified: tools/russconnectd/trunk/debian/changelog
===================================================================
--- tools/russconnectd/trunk/debian/changelog 2011-12-28 00:15:30 UTC (rev 613)
+++ tools/russconnectd/trunk/debian/changelog 2011-12-28 18:37:09 UTC (rev 614)
@@ -1,3 +1,9 @@
+russconnectd (0.21-1) lenny; urgency=low
+
+ * fixes/new upstream
+
+ -- Michael Markstaller <de...@wi...> Wed, 28 Dec 2011 19:29:58 +0100
+
russconnectd (0.2-3) lenny; urgency=low
* rebuild for lenny
Modified: tools/russconnectd/trunk/debian/files
===================================================================
--- tools/russconnectd/trunk/debian/files 2011-12-28 00:15:30 UTC (rev 613)
+++ tools/russconnectd/trunk/debian/files 2011-12-28 18:37:09 UTC (rev 614)
@@ -1 +1 @@
-russconnectd_0.2-3_i386.deb unknown extra
+russconnectd_0.21-1_i386.deb unknown extra
Modified: tools/russconnectd/trunk/src/main.c
===================================================================
--- tools/russconnectd/trunk/src/main.c 2011-12-28 00:15:30 UTC (rev 613)
+++ tools/russconnectd/trunk/src/main.c 2011-12-28 18:37:09 UTC (rev 614)
@@ -140,6 +140,19 @@
void *sendrussPolling(unsigned char zone) {
syslog(LOG_DEBUG, "polling zone %d",zone);
pthread_mutex_trylock(&standbylock);
+
+ //Send device reset-event to wakeup (at least) C3 - yet untested
+ if (keypadid == 0x71) {
+ char buf_devreset[25] = { 0xF0, 0, 0, 0x7F, 0, 0, keypadid, 0x05, 0x02, 0x02, 0, 0, 0x55, 0x01, 0x03, 0, 0x35, 0, 0x01, 0, 0xF7 };
+ buf_devreset[4] = zone/ZONES_PER_CONTROLLER;
+ buf_devreset[5] = zone%ZONES_PER_CONTROLLER;
+ buf_devreset[19] = (int) russChecksum (buf_devreset,21-2);
+ if (sendto(udpSocket, buf_devreset, 21, 0, (struct sockaddr *) &si_other, slen)==-1)
+ syslog(LOG_WARNING,"sendto failed!");
+ usleep(20*1000); //FIXME: throttle a little
+ }
+
+ //Get Poweron-Volume
char buf_onvol[25] = { 0xF0, 0, 0, 0x7F, 0, 0, keypadid, 0x01, 0x05, 0x02, 0, 0, 0, 0x04, 0, 0, 0, 0xF7 };
buf_onvol[1] = zone/ZONES_PER_CONTROLLER;
buf_onvol[11] = zone%ZONES_PER_CONTROLLER;
@@ -148,6 +161,7 @@
syslog(LOG_WARNING,"sendto failed!");
usleep(20*1000); //FIXME: throttle a little (20ms)
+ //Get zonestate
char buf_getzone[25] = { 0xF0, 0, 0, 0x7F, 0, 0, keypadid, 0x01, 0x04, 0x02, 0, 0, 0x07, 0, 0, 0, 0xF7 };
buf_getzone[1] = zone/ZONES_PER_CONTROLLER;
buf_getzone[11] = zone%ZONES_PER_CONTROLLER;
@@ -199,12 +213,18 @@
break;
case 3: //bass
buf_msg2[0] = 0xF0;
- buf_msg2[21] = val;
+ if (val>127)
+ buf_msg2[21] = val-256+10;
+ else
+ buf_msg2[21] = val+10;
break;
case 4: //treb
buf_msg2[0] = 0xF0;
buf_msg2[13] = 0x01;
- buf_msg2[21] = val;
+ if (val>127)
+ buf_msg2[21] = val-256+10;
+ else
+ buf_msg2[21] = val+10;
break;
case 5: //loud
buf_msg2[0] = 0xF0;
@@ -787,7 +807,7 @@
if (!daemonize) {
setlogmask(LOG_UPTO(LOG_DEBUG));
openlog(DAEMON_NAME, LOG_CONS | LOG_NDELAY | LOG_PERROR | LOG_PID, LOG_USER);
- syslog(LOG_DEBUG, "startup with debug; Russ-IP: %s:%d, listenport %d, pidfile: %s, start address: %d, number of zones: %d, eibd: %s SendonStartup: %d KeypadID: %d",
+ syslog(LOG_DEBUG, "startup with debug; Russ-IP: %s:%d, listenport %d, pidfile: %s, start address: %d, number of zones: %d, eibd: %s SendonStartup: %d KeypadID: %li",
russipaddr, russport, listenport, pidfilename, knxstartaddress, numzones, eibd_url, sendOnStart, keypadid);
} else {
setlogmask(LOG_UPTO(LOG_INFO));
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-28 00:15:37
|
Revision: 613
http://openautomation.svn.sourceforge.net/openautomation/?rev=613&view=rev
Author: makki1
Date: 2011-12-28 00:15:30 +0000 (Wed, 28 Dec 2011)
Log Message:
-----------
Change cfgmaker to new infotrigger, various small adjustments, there is still a HEAVY bug in setting Bass/Treble if no absolute values are used though, be aware..
Modified Paths:
--------------
tools/russconnectd/trunk/ChangeLog
tools/russconnectd/trunk/Makefile.am
tools/russconnectd/trunk/cfgmaker.pl
tools/russconnectd/trunk/debian/changelog
tools/russconnectd/trunk/debian/files
tools/russconnectd/trunk/debian/russconnectd.default
Modified: tools/russconnectd/trunk/ChangeLog
===================================================================
--- tools/russconnectd/trunk/ChangeLog 2011-12-26 22:05:37 UTC (rev 612)
+++ tools/russconnectd/trunk/ChangeLog 2011-12-28 00:15:30 UTC (rev 613)
@@ -1,3 +1,7 @@
+*** trunk - 2011-12-28
+- WiP - not yet done: C3-support - (maybe also needed for C5/E5) send Device restart event to start RNet-communication
+- Fix cfgmaker for CometVisu, adjust to new infotrigger
+
*** 0.2 - 2011-10-15
- global UDP-socket sending with listen port as source to make socat happy
- parse partial/fragmented messages from Russound (WiP still pending fragments with multiple msg)
Modified: tools/russconnectd/trunk/Makefile.am
===================================================================
--- tools/russconnectd/trunk/Makefile.am 2011-12-26 22:05:37 UTC (rev 612)
+++ tools/russconnectd/trunk/Makefile.am 2011-12-28 00:15:30 UTC (rev 613)
@@ -11,7 +11,8 @@
ChangeLog\
INSTALL\
NEWS\
- russ_galist.ods
+ russ_galist.ods\
+ cfgmaker.pl
INTLTOOL_FILES = intltool-extract.in \
Modified: tools/russconnectd/trunk/cfgmaker.pl
===================================================================
--- tools/russconnectd/trunk/cfgmaker.pl 2011-12-26 22:05:37 UTC (rev 612)
+++ tools/russconnectd/trunk/cfgmaker.pl 2011-12-28 00:15:30 UTC (rev 613)
@@ -57,6 +57,16 @@
print VISU1 " <page name=\"$NamePrefix\">\n";
+print VISU2 "<!-- Change SourceNames in script and insert this on top between <mappings> and </mappings> -->\n";
+print VISU2 " <mapping name=\"RussoundSRC\">\n"
+." <entry value=\"0\">$SourceNames[0]</entry>\n"
+." <entry value=\"1\">$SourceNames[1]</entry>\n"
+." <entry value=\"2\">$SourceNames[2]</entry>\n"
+." <entry value=\"3\">$SourceNames[3]</entry>\n"
+." <entry value=\"4\">$SourceNames[4]</entry>\n"
+." <entry value=\"5\">$SourceNames[5]</entry>\n"
+." </mapping>\n\n\n";
+
# Globals
$conf->{addr2str($startga+1,1)}->{'name'} = $NamePrefix . " " . $gfuncnames[0];
$conf->{addr2str($startga+1,1)}->{'DPTSubId'} = 1.001;
@@ -93,7 +103,7 @@
print ESF "$NamePrefix.Controller$ctrl." . addr2str($basega+$i+20,1) . "\t" . "$NamePrefix $zonenames[$zone] C" . ($ctrl+1) . "-Z" . ($czone+1) . " $statenames[$i]" . "\t" . $EISmap{$statedpts[$i]} . "\tLow\n";
print XML "\t\t<object id=\"$zonenames[$zone]_C" . ($ctrl+1) . "_Z" . ($czone+1) . "_" . "$statenames[$i]\" gad=\"" . addr2str($basega+$i+20,1) . "\" type=\"$statedpts[$i]\">" . "$NamePrefix $zonenames[$zone] (C" . ($ctrl+1) . "/Z" . ($czone+1) . ") $statenames[$i]" . "</object>\n";
}
- print VISU1 ' <switch mapping="OnOff" styling="RedGreen">'
+ print VISU1 ' <switch mapping="OnOff" styling="GreenRed">'
."\n <label>$zonenames[$zone]</label>\n"
.' <address transform="DPT:1.001" readonly="false" type="">' . addr2str($basega,1) . "</address>\n"
.' <address transform="DPT:1.001" readonly="true" type="">' . addr2str($basega+20,1) . "</address>\n"
@@ -103,74 +113,71 @@
.' <address transform="DPT:5.001" readonly="false" type="">' . addr2str($basega+2,1) . "</address>\n"
.' <address transform="DPT:5.001" readonly="true" type="">' . addr2str($basega+22,1) . "</address>\n"
." </slide>\n";
+
print VISU2 " <page name=\"$NamePrefix $zonenames[$zone]\">\n";
- print VISU2 ' <switch mapping="OnOff" styling="RedGreen">'
+ print VISU2 ' <switch mapping="OnOff" styling="GreenRed">'
."\n <label>Power</label>\n"
.' <address transform="DPT:1.001" readonly="false" type="">' . addr2str($basega,1) . "</address>\n"
.' <address transform="DPT:1.001" readonly="true" type="">' . addr2str($basega+20,1) . "</address>\n"
." </switch>\n";
print VISU2 ' <slide min="0" max="100">'
- ."\n <label>Vol</label>\n"
+ ."\n <label>Volume</label>\n"
.' <address transform="DPT:5.001" readonly="false" type="">' . addr2str($basega+2,1) . "</address>\n"
.' <address transform="DPT:5.001" readonly="true" type="">' . addr2str($basega+22,1) . "</address>\n"
." </slide>\n";
- print VISU2 ' <info format="">'
- ."\n <label>Source</label>\n"
- .' <address transform="DPT:5.010" readonly="false" type="">' . addr2str($basega+1,1) . "</address>\n"
- .' <address transform="DPT:5.010" readonly="true" type="">' . addr2str($basega+21,1) . "</address>\n"
- ." </info>\n";
- print VISU2 " <multitrigger button1label=\"$SourceNames[0]\" button1value=\"0\" button2label=\"$SourceNames[1]\" button2value=\"1\" button3label=\"$SourceNames[2]\" button3value=\"2\" button4label=\"$SourceNames[3]\" button4value=\"3\">"
- ."\n <label>Source</label>\n"
- .' <address transform="DPT:5.010" readonly="false" type="">' . addr2str($basega+1,1) . "</address>\n"
- .' <address transform="DPT:5.010" readonly="true" type="">' . addr2str($basega+21,1) . "</address>\n"
- ." </multitrigger>\n";
- print VISU2 " <multitrigger button1label=\"$SourceNames[4]\" button1value=\"4\" button2label=\"$SourceNames[5]\" button2value=\"5\">"
- ."\n <label>Source</label>\n"
- .' <address transform="DPT:5.010" readonly="false" type="">' . addr2str($basega+1,1) . "</address>\n"
- .' <address transform="DPT:5.010" readonly="true" type="">' . addr2str($basega+21,1) . "</address>\n"
- ." </multitrigger>\n";
- print VISU2 ' <switch mapping="OnOff" styling="RedGreen">'
+ #$SourceNames[0]
+ print VISU2 ' <infotrigger uplabel=">" upvalue="1" downlabel="<" downvalue="-1" align="center" infoposition="1" change="absolute" min="0" max="5" mapping="RussoundSRC">'
+# <infotrigger uplabel=">" upvalue="1" downlabel="<" downvalue="-1" align="center" infoposition="1" change="absolute" min="0" max="5" mapping="RussoundSRC">
+# <label>Source</label>
+# <address transform="DPT:5.010" readonly="false" variant="">10/1/11</address>
+# <address transform="DPT:5.010" readonly="true" variant="">10/1/31</address>
+# </infotrigger>
+ ."\n <label>Quelle</label>\n"
+ .' <address transform="DPT:5.010" readonly="false">' . addr2str($basega+1,1) . "</address>\n"
+ .' <address transform="DPT:5.010" readonly="true">' . addr2str($basega+21,1) . "</address>\n"
+ ." </infotrigger>\n";
+ print VISU2 ' <switch mapping="OnOff" styling="GreenRed">'
."\n <label>Loudness</label>\n"
.' <address transform="DPT:1.001" readonly="false" type="">' . addr2str($basega+5,1) . "</address>\n"
.' <address transform="DPT:1.001" readonly="true" type="">' . addr2str($basega+25,1) . "</address>\n"
." </switch>\n";
- print VISU2 ' <infotrigger button1label="+" button1value="1" button2label="-" button2value="0" align="center" infoposition="1" format="%.0f %%">'
+ print VISU2 ' <infotrigger button1label="+" button1value="1" button2label="-" button2value="0" align="center" infoposition="1" format="%.0f %% ">'
."\n <label>Volume</label>\n"
- .' <address transform="DPT:1.008" readonly="false" type="">' . addr2str($basega+12,1) . "</address>\n"
- .' <address transform="DPT:5.001" readonly="true" type="">' . addr2str($basega+2,1) . "</address>\n"
- .' <address transform="DPT:5.001" readonly="true" type="">' . addr2str($basega+22,1) . "</address>\n"
+ .' <address transform="DPT:1.008" readonly="false" variant="button">' . addr2str($basega+12,1) . "</address>\n"
+ .' <address transform="DPT:5.001" readonly="true" variant="">' . addr2str($basega+2,1) . "</address>\n"
+ .' <address transform="DPT:5.001" readonly="true" variant="">' . addr2str($basega+22,1) . "</address>\n"
." </infotrigger>\n";
- print VISU2 ' <info format="%.0f %%">'
- ."\n <label>TurnOn Vol</label>\n"
+ print VISU2 ' <infotrigger align="center" infoposition="1" upvalue="2" downvalue="-2" change="absolute" format="%.0f %%">'
+ ."\n <label>TurnOn Volume</label>\n"
.' <address transform="DPT:5.001" readonly="false" type="">' . addr2str($basega+9,1) . "</address>\n"
.' <address transform="DPT:5.001" readonly="true" type="">' . addr2str($basega+29,1) . "</address>\n"
- ." </info>\n";
- print VISU2 ' <slide min="0" max="100">'
- ."\n <label>TurnOn Vol</label>\n"
- .' <address transform="DPT:5.001" readonly="false" type="">' . addr2str($basega+9,1) . "</address>\n"
- .' <address transform="DPT:5.001" readonly="true" type="">' . addr2str($basega+29,1) . "</address>\n"
- ." </slide>\n";
- print VISU2 ' <slide min="-10" max="10">'
+ ." </infotrigger>\n";
+# print VISU2 ' <slide min="0" max="100">'
+# ."\n <label>TurnOn Vol</label>\n"
+# .' <address transform="DPT:5.001" readonly="false" type="">' . addr2str($basega+9,1) . "</address>\n"
+# .' <address transform="DPT:5.001" readonly="true" type="">' . addr2str($basega+29,1) . "</address>\n"
+# ." </slide>\n";
+ print VISU2 ' <infotrigger align="center" infoposition="1" upvalue="1" downvalue="-1" change="absolute" min="-10" max="10">'
."\n <label>Bass</label>\n"
.' <address transform="DPT:6.001" readonly="false" type="">' . addr2str($basega+3,1) . "</address>\n"
.' <address transform="DPT:6.001" readonly="true" type="">' . addr2str($basega+23,1) . "</address>\n"
- ." </slide>\n";
- print VISU2 ' <slide min="-10" max="10">'
+ ." </infotrigger>\n";
+ print VISU2 ' <infotrigger align="center" infoposition="1" upvalue="1" downvalue="-1" change="absolute" min="-10" max="10">'
."\n <label>Treble</label>\n"
.' <address transform="DPT:6.001" readonly="false" type="">' . addr2str($basega+4,1) . "</address>\n"
.' <address transform="DPT:6.001" readonly="true" type="">' . addr2str($basega+24,1) . "</address>\n"
- ." </slide>\n";
- print VISU2 ' <slide min="-10" max="10">'
+ ." </infotrigger>\n";
+ print VISU2 ' <infotrigger align="center" infoposition="1" upvalue="1" downvalue="-1" change="absolute" min="-10" max="10">'
."\n <label>Balance</label>\n"
.' <address transform="DPT:6.001" readonly="false" type="">' . addr2str($basega+6,1) . "</address>\n"
.' <address transform="DPT:6.001" readonly="true" type="">' . addr2str($basega+26,1) . "</address>\n"
- ." </slide>\n";
- print VISU2 ' <switch mapping="OnOff" styling="RedGreen">'
+ ." </infotrigger>\n";
+ print VISU2 ' <switch mapping="OnOff" styling="GreenRed">'
."\n <label>Party</label>\n"
.' <address transform="DPT:1.001" readonly="false" type="">' . addr2str($basega+7,1) . "</address>\n"
.' <address transform="DPT:1.001" readonly="true" type="">' . addr2str($basega+27,1) . "</address>\n"
." </switch>\n";
- print VISU2 ' <switch mapping="OnOff" styling="RedGreen">'
+ print VISU2 ' <switch mapping="OnOff" styling="GreenRed">'
."\n <label>DnD</label>\n"
.' <address transform="DPT:1.001" readonly="false" type="">' . addr2str($basega+8,1) . "</address>\n"
.' <address transform="DPT:1.001" readonly="true" type="">' . addr2str($basega+28,1) . "</address>\n"
Modified: tools/russconnectd/trunk/debian/changelog
===================================================================
--- tools/russconnectd/trunk/debian/changelog 2011-12-26 22:05:37 UTC (rev 612)
+++ tools/russconnectd/trunk/debian/changelog 2011-12-28 00:15:30 UTC (rev 613)
@@ -1,3 +1,9 @@
+russconnectd (0.2-3) lenny; urgency=low
+
+ * rebuild for lenny
+
+ -- Michael Markstaller <de...@wi...> Sat, 22 Oct 2011 11:05:32 +0200
+
russconnectd (0.2-ubuntu1) oneiric; urgency=low
* new upstream
Modified: tools/russconnectd/trunk/debian/files
===================================================================
--- tools/russconnectd/trunk/debian/files 2011-12-26 22:05:37 UTC (rev 612)
+++ tools/russconnectd/trunk/debian/files 2011-12-28 00:15:30 UTC (rev 613)
@@ -1 +1 @@
-russconnectd_0.2-ubuntu1_i386.deb unknown extra
+russconnectd_0.2-3_i386.deb unknown extra
Modified: tools/russconnectd/trunk/debian/russconnectd.default
===================================================================
--- tools/russconnectd/trunk/debian/russconnectd.default 2011-12-26 22:05:37 UTC (rev 612)
+++ tools/russconnectd/trunk/debian/russconnectd.default 2011-12-28 00:15:30 UTC (rev 613)
@@ -13,7 +13,9 @@
# -a <KNX address> KNX start-address (see README)
# -z <number> Number of Zones to support
# -u <eib url> URL to conatct eibd like localo:/tmp/eib or ip:192.168.0.101
+# -s (Optional) send all values to KNX on startup of daemon
+# -k 0x71 (Optional) Keypad ID - defaults to 0x70 for CAx - use 0x71 for C5
# Additional options that are passed to the Daemon.
-DAEMON_ARGS="-d -i 127.0.0.1:16012 -l 16011 -a 10/1/0 -z 6 -u local:/tmp/eib"
+DAEMON_ARGS="-d -i 127.0.0.1:16012 -l 16011 -a 10/1/0 -z 6 -u local:/tmp/eib -s"
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <pan...@us...> - 2011-12-26 22:05:45
|
Revision: 612
http://openautomation.svn.sourceforge.net/openautomation/?rev=612&view=rev
Author: panzaeron
Date: 2011-12-26 22:05:37 +0000 (Mon, 26 Dec 2011)
Log Message:
-----------
Change the font for alaska visu
Modified Paths:
--------------
CometVisu/trunk/visu/designs/alaska/basic.css
CometVisu/trunk/visu/designs/alaska_slim/basic.css
Added Paths:
-----------
CometVisu/trunk/visu/designs/alaska/fonts/LICENSE.txt
CometVisu/trunk/visu/designs/alaska/fonts/Tuffy.ttf
CometVisu/trunk/visu/designs/alaska/fonts/Tuffy_Bold.ttf
Removed Paths:
-------------
CometVisu/trunk/visu/designs/alaska/fonts/AUTHORS
CometVisu/trunk/visu/designs/alaska/fonts/COPYING
CometVisu/trunk/visu/designs/alaska/fonts/ChangeLog
CometVisu/trunk/visu/designs/alaska/fonts/License.txt
CometVisu/trunk/visu/designs/alaska/fonts/README
CometVisu/trunk/visu/designs/alaska/fonts/TODO
CometVisu/trunk/visu/designs/alaska/fonts/alaska_black_nocaps.ttf
CometVisu/trunk/visu/designs/alaska/fonts/alaska_light_nocaps.ttf
CometVisu/trunk/visu/designs/alaska_slim/fonts/
Modified: CometVisu/trunk/visu/designs/alaska/basic.css
===================================================================
--- CometVisu/trunk/visu/designs/alaska/basic.css 2011-12-26 21:33:53 UTC (rev 611)
+++ CometVisu/trunk/visu/designs/alaska/basic.css 2011-12-26 22:05:37 UTC (rev 612)
@@ -1,10 +1,10 @@
@import "colors.css";
-@font-face { font-family: alaska; src:url(fonts/alaska_light_nocaps.ttf); }
-@font-face { font-family: alaska; font-weight: bold; src:url(fonts/alaska_black_nocaps.ttf); }
+@font-face { font-family: Tuffy; src:url(fonts/Tuffy.ttf); }
+@font-face { font-family: Tuffy; font-weight: bold; src:url(fonts/Tuffy_Bold.ttf); }
body
{
- font-family: alaska,sans-serif;
+ font-family: Tuffy,sans-serif;
font-size: 5.5mm;
overflow: hidden;
margin:0;
@@ -414,4 +414,4 @@
div#demo_3 {
display: none;
-}
\ No newline at end of file
+}
Deleted: CometVisu/trunk/visu/designs/alaska/fonts/AUTHORS
===================================================================
--- CometVisu/trunk/visu/designs/alaska/fonts/AUTHORS 2011-12-26 21:33:53 UTC (rev 611)
+++ CometVisu/trunk/visu/designs/alaska/fonts/AUTHORS 2011-12-26 22:05:37 UTC (rev 612)
@@ -1,23 +0,0 @@
-AUTHORS
-
-Current Contributors (sorted alphabetically):
-
- - Caius 'kaio' Chance <caius.chance at gmail.com>
- Project Owner
- Red Hat, Inc.
-
- - Denis Jacquerye <moyogo at gmail.com>
- Project Contributor
-
- - Herbert Duerr <duerr at sun.com>
- Narrow Fonts Contributor
- Oracle, Inc.
-
-Previous Contributors
-
- - Steve Matteson
- Original Designer (support period expired)
- Ascender, Inc.
-
- - Mark Webbink <mwebbink AT redhat.com>
- Release coordinator, Red Hat Inc.
Deleted: CometVisu/trunk/visu/designs/alaska/fonts/COPYING
===================================================================
--- CometVisu/trunk/visu/designs/alaska/fonts/COPYING 2011-12-26 21:33:53 UTC (rev 611)
+++ CometVisu/trunk/visu/designs/alaska/fonts/COPYING 2011-12-26 22:05:37 UTC (rev 612)
@@ -1,339 +0,0 @@
- GNU GENERAL PUBLIC LICENSE
- Version 2, June 1991
-
- Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
- 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
- Preamble
-
- The licenses for most software are designed to take away your
-freedom to share and change it. By contrast, the GNU General Public
-License is intended to guarantee your freedom to share and change free
-software--to make sure the software is free for all its users. This
-General Public License applies to most of the Free Software
-Foundation's software and to any other program whose authors commit to
-using it. (Some other Free Software Foundation software is covered by
-the GNU Lesser General Public License instead.) You can apply it to
-your programs, too.
-
- When we speak of free software, we are referring to freedom, not
-price. Our General Public Licenses are designed to make sure that you
-have the freedom to distribute copies of free software (and charge for
-this service if you wish), that you receive source code or can get it
-if you want it, that you can change the software or use pieces of it
-in new free programs; and that you know you can do these things.
-
- To protect your rights, we need to make restrictions that forbid
-anyone to deny you these rights or to ask you to surrender the rights.
-These restrictions translate to certain responsibilities for you if you
-distribute copies of the software, or if you modify it.
-
- For example, if you distribute copies of such a program, whether
-gratis or for a fee, you must give the recipients all the rights that
-you have. You must make sure that they, too, receive or can get the
-source code. And you must show them these terms so they know their
-rights.
-
- We protect your rights with two steps: (1) copyright the software, and
-(2) offer you this license which gives you legal permission to copy,
-distribute and/or modify the software.
-
- Also, for each author's protection and ours, we want to make certain
-that everyone understands that there is no warranty for this free
-software. If the software is modified by someone else and passed on, we
-want its recipients to know that what they have is not the original, so
-that any problems introduced by others will not reflect on the original
-authors' reputations.
-
- Finally, any free program is threatened constantly by software
-patents. We wish to avoid the danger that redistributors of a free
-program will individually obtain patent licenses, in effect making the
-program proprietary. To prevent this, we have made it clear that any
-patent must be licensed for everyone's free use or not licensed at all.
-
- The precise terms and conditions for copying, distribution and
-modification follow.
-
- GNU GENERAL PUBLIC LICENSE
- TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
-
- 0. This License applies to any program or other work which contains
-a notice placed by the copyright holder saying it may be distributed
-under the terms of this General Public License. The "Program", below,
-refers to any such program or work, and a "work based on the Program"
-means either the Program or any derivative work under copyright law:
-that is to say, a work containing the Program or a portion of it,
-either verbatim or with modifications and/or translated into another
-language. (Hereinafter, translation is included without limitation in
-the term "modification".) Each licensee is addressed as "you".
-
-Activities other than copying, distribution and modification are not
-covered by this License; they are outside its scope. The act of
-running the Program is not restricted, and the output from the Program
-is covered only if its contents constitute a work based on the
-Program (independent of having been made by running the Program).
-Whether that is true depends on what the Program does.
-
- 1. You may copy and distribute verbatim copies of the Program's
-source code as you receive it, in any medium, provided that you
-conspicuously and appropriately publish on each copy an appropriate
-copyright notice and disclaimer of warranty; keep intact all the
-notices that refer to this License and to the absence of any warranty;
-and give any other recipients of the Program a copy of this License
-along with the Program.
-
-You may charge a fee for the physical act of transferring a copy, and
-you may at your option offer warranty protection in exchange for a fee.
-
- 2. You may modify your copy or copies of the Program or any portion
-of it, thus forming a work based on the Program, and copy and
-distribute such modifications or work under the terms of Section 1
-above, provided that you also meet all of these conditions:
-
- a) You must cause the modified files to carry prominent notices
- stating that you changed the files and the date of any change.
-
- b) You must cause any work that you distribute or publish, that in
- whole or in part contains or is derived from the Program or any
- part thereof, to be licensed as a whole at no charge to all third
- parties under the terms of this License.
-
- c) If the modified program normally reads commands interactively
- when run, you must cause it, when started running for such
- interactive use in the most ordinary way, to print or display an
- announcement including an appropriate copyright notice and a
- notice that there is no warranty (or else, saying that you provide
- a warranty) and that users may redistribute the program under
- these conditions, and telling the user how to view a copy of this
- License. (Exception: if the Program itself is interactive but
- does not normally print such an announcement, your work based on
- the Program is not required to print an announcement.)
-
-These requirements apply to the modified work as a whole. If
-identifiable sections of that work are not derived from the Program,
-and can be reasonably considered independent and separate works in
-themselves, then this License, and its terms, do not apply to those
-sections when you distribute them as separate works. But when you
-distribute the same sections as part of a whole which is a work based
-on the Program, the distribution of the whole must be on the terms of
-this License, whose permissions for other licensees extend to the
-entire whole, and thus to each and every part regardless of who wrote it.
-
-Thus, it is not the intent of this section to claim rights or contest
-your rights to work written entirely by you; rather, the intent is to
-exercise the right to control the distribution of derivative or
-collective works based on the Program.
-
-In addition, mere aggregation of another work not based on the Program
-with the Program (or with a work based on the Program) on a volume of
-a storage or distribution medium does not bring the other work under
-the scope of this License.
-
- 3. You may copy and distribute the Program (or a work based on it,
-under Section 2) in object code or executable form under the terms of
-Sections 1 and 2 above provided that you also do one of the following:
-
- a) Accompany it with the complete corresponding machine-readable
- source code, which must be distributed under the terms of Sections
- 1 and 2 above on a medium customarily used for software interchange; or,
-
- b) Accompany it with a written offer, valid for at least three
- years, to give any third party, for a charge no more than your
- cost of physically performing source distribution, a complete
- machine-readable copy of the corresponding source code, to be
- distributed under the terms of Sections 1 and 2 above on a medium
- customarily used for software interchange; or,
-
- c) Accompany it with the information you received as to the offer
- to distribute corresponding source code. (This alternative is
- allowed only for noncommercial distribution and only if you
- received the program in object code or executable form with such
- an offer, in accord with Subsection b above.)
-
-The source code for a work means the preferred form of the work for
-making modifications to it. For an executable work, complete source
-code means all the source code for all modules it contains, plus any
-associated interface definition files, plus the scripts used to
-control compilation and installation of the executable. However, as a
-special exception, the source code distributed need not include
-anything that is normally distributed (in either source or binary
-form) with the major components (compiler, kernel, and so on) of the
-operating system on which the executable runs, unless that component
-itself accompanies the executable.
-
-If distribution of executable or object code is made by offering
-access to copy from a designated place, then offering equivalent
-access to copy the source code from the same place counts as
-distribution of the source code, even though third parties are not
-compelled to copy the source along with the object code.
-
- 4. You may not copy, modify, sublicense, or distribute the Program
-except as expressly provided under this License. Any attempt
-otherwise to copy, modify, sublicense or distribute the Program is
-void, and will automatically terminate your rights under this License.
-However, parties who have received copies, or rights, from you under
-this License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
- 5. You are not required to accept this License, since you have not
-signed it. However, nothing else grants you permission to modify or
-distribute the Program or its derivative works. These actions are
-prohibited by law if you do not accept this License. Therefore, by
-modifying or distributing the Program (or any work based on the
-Program), you indicate your acceptance of this License to do so, and
-all its terms and conditions for copying, distributing or modifying
-the Program or works based on it.
-
- 6. Each time you redistribute the Program (or any work based on the
-Program), the recipient automatically receives a license from the
-original licensor to copy, distribute or modify the Program subject to
-these terms and conditions. You may not impose any further
-restrictions on the recipients' exercise of the rights granted herein.
-You are not responsible for enforcing compliance by third parties to
-this License.
-
- 7. If, as a consequence of a court judgment or allegation of patent
-infringement or for any other reason (not limited to patent issues),
-conditions are imposed on you (whether by court order, agreement or
-otherwise) that contradict the conditions of this License, they do not
-excuse you from the conditions of this License. If you cannot
-distribute so as to satisfy simultaneously your obligations under this
-License and any other pertinent obligations, then as a consequence you
-may not distribute the Program at all. For example, if a patent
-license would not permit royalty-free redistribution of the Program by
-all those who receive copies directly or indirectly through you, then
-the only way you could satisfy both it and this License would be to
-refrain entirely from distribution of the Program.
-
-If any portion of this section is held invalid or unenforceable under
-any particular circumstance, the balance of the section is intended to
-apply and the section as a whole is intended to apply in other
-circumstances.
-
-It is not the purpose of this section to induce you to infringe any
-patents or other property right claims or to contest validity of any
-such claims; this section has the sole purpose of protecting the
-integrity of the free software distribution system, which is
-implemented by public license practices. Many people have made
-generous contributions to the wide range of software distributed
-through that system in reliance on consistent application of that
-system; it is up to the author/donor to decide if he or she is willing
-to distribute software through any other system and a licensee cannot
-impose that choice.
-
-This section is intended to make thoroughly clear what is believed to
-be a consequence of the rest of this License.
-
- 8. If the distribution and/or use of the Program is restricted in
-certain countries either by patents or by copyrighted interfaces, the
-original copyright holder who places the Program under this License
-may add an explicit geographical distribution limitation excluding
-those countries, so that distribution is permitted only in or among
-countries not thus excluded. In such case, this License incorporates
-the limitation as if written in the body of this License.
-
- 9. The Free Software Foundation may publish revised and/or new versions
-of the General Public License from time to time. Such new versions will
-be similar in spirit to the present version, but may differ in detail to
-address new problems or concerns.
-
-Each version is given a distinguishing version number. If the Program
-specifies a version number of this License which applies to it and "any
-later version", you have the option of following the terms and conditions
-either of that version or of any later version published by the Free
-Software Foundation. If the Program does not specify a version number of
-this License, you may choose any version ever published by the Free Software
-Foundation.
-
- 10. If you wish to incorporate parts of the Program into other free
-programs whose distribution conditions are different, write to the author
-to ask for permission. For software which is copyrighted by the Free
-Software Foundation, write to the Free Software Foundation; we sometimes
-make exceptions for this. Our decision will be guided by the two goals
-of preserving the free status of all derivatives of our free software and
-of promoting the sharing and reuse of software generally.
-
- NO WARRANTY
-
- 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
-FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
-OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
-PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
-OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
-TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
-PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
-REPAIR OR CORRECTION.
-
- 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
-WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
-REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
-INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
-OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
-TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
-YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
-PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
-POSSIBILITY OF SUCH DAMAGES.
-
- END OF TERMS AND CONDITIONS
-
- How to Apply These Terms to Your New Programs
-
- If you develop a new program, and you want it to be of the greatest
-possible use to the public, the best way to achieve this is to make it
-free software which everyone can redistribute and change under these terms.
-
- To do so, attach the following notices to the program. It is safest
-to attach them to the start of each source file to most effectively
-convey the exclusion of warranty; and each file should have at least
-the "copyright" line and a pointer to where the full notice is found.
-
- <one line to give the program's name and a brief idea of what it does.>
- Copyright (C) <year> <name of author>
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License along
- with this program; if not, write to the Free Software Foundation, Inc.,
- 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-
-Also add information on how to contact you by electronic and paper mail.
-
-If the program is interactive, make it output a short notice like this
-when it starts in an interactive mode:
-
- Gnomovision version 69, Copyright (C) year name of author
- Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
- This is free software, and you are welcome to redistribute it
- under certain conditions; type `show c' for details.
-
-The hypothetical commands `show w' and `show c' should show the appropriate
-parts of the General Public License. Of course, the commands you use may
-be called something other than `show w' and `show c'; they could even be
-mouse-clicks or menu items--whatever suits your program.
-
-You should also get your employer (if you work as a programmer) or your
-school, if any, to sign a "copyright disclaimer" for the program, if
-necessary. Here is a sample; alter the names:
-
- Yoyodyne, Inc., hereby disclaims all copyright interest in the program
- `Gnomovision' (which makes passes at compilers) written by James Hacker.
-
- <signature of Ty Coon>, 1 April 1989
- Ty Coon, President of Vice
-
-This General Public License does not permit incorporating your program into
-proprietary programs. If your program is a subroutine library, you may
-consider it more useful to permit linking proprietary applications with the
-library. If this is what you want to do, use the GNU Lesser General
-Public License instead of this License.
Deleted: CometVisu/trunk/visu/designs/alaska/fonts/ChangeLog
===================================================================
--- CometVisu/trunk/visu/designs/alaska/fonts/ChangeLog 2011-12-26 21:33:53 UTC (rev 611)
+++ CometVisu/trunk/visu/designs/alaska/fonts/ChangeLog 2011-12-26 22:05:37 UTC (rev 612)
@@ -1,224 +0,0 @@
-* Wed Jul 21 2010 Pravin Satpute <psa...@re...>
-- Update for New Release 1.06
-- Added New Family Narrow (Contribution from Herbert Duerr <her...@or...>)
-- updated version of fonts
-
-* Mon 10 May 2010 Caius 'kaio' Chance <me at kaio.net>
-- Fixed Romanian glyphs, U+021A, 021B, 0218, 0219, 0162, 0163, 015E, 015F,
- 2010, 2011. (rhbz#440992)
-- Fixed height of arrows U+2190, 2192, 2194. (Issue #2)
-
-* Thu 06 May 2010 Caius 'kaio' Chance <me at kaio.net>
-- Cleaned up points and auto-instructed hinting of 'u', 'v', 'w', 'y'.
-(rhbz#463036)
-- Created the first project icon. (Issue #5)
-
-* Wed May 05 2010 Caius 'kaio' Chance <k at kaio.net>
-- Incorrect cent sign glyph (U+00A2) in Sans and Mono
-style in Liberation fonts. (rhbz#474522)
-
-* Wed 28 Apr 2010 Caius 'kaio' Chance <me at kaio.net>
-- rhbz#510174: Corrected version number of all SFD files.
-- Corrected license exceptions to GPLv2.
-- Updated README file.
-
-* Tue 27 Apr 2010 Caius 'kaio' Chance <me at kaio.net>
-- Renamed Narrow Fonts.
-- Updated list of contributors.
-- Released version 1.05.3.
-
-* Thu 22 Apr 2010 Herbert Duerr <duerr at sun.com>
-- Contributed Liberation Sans Narrow Fonts.
-
-* Fri 12 Mar 2010 Caius 'kaio' Chance <me at kaio.me>
-- Migrated to Google Code.
-- Updated AUTHORS.
-- Upgraded license to GPLv3+exceptions.
-
-* Sun 27 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Fixed ttf pack preparation error.
-
-* Tue 21 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Fixed 'wrongly encoded glyphs after U+10000' (rhbz#525498),
- provided by Denis Jacquerye <moyogo at gmail.com>.
-
-* Tue 21 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Fixed fontforge script sfd2ttf.pe.
-- Include traditional kern table for Sans and Serif.
-
-* Tue 14 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Generated TTFs with tradition kern table, with fontforge ver 20090408.
-- Added make target alias dist-src as dist-sfd.
-
-* Mon 13 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Updated for generation of traditional kern table via scripts.
-
-* Mon 06 Jul 2009 Caius 'kaio' Chance <me at kaio.me>
-- Reconverted SFDs from original TTFs with traditional kern table.
-- Updated "clean" target in Makefile.
-
-* Tue 30 Jun 2009 Caius 'kaio' Chance <me at kaio.me>
-- Reconverted SFDs from original TTFs with traditional kern table.
-- Updated "clean" target in Makefile.
-
-* Tue 30 Jun 2009 Caius 'kaio' Chance <me at kaio.me>
-- Generated cleaner SFD from original TTFs.
-- Include Makefile in sources tarball.
-
-* Wed 24 Jun 2009 Caius 'kaio' Chance <me at kaio.me>
-- Makefile: pack SFD files as source tarball.
-- Makefile: pack TTF files as ttf packs.
-- Tidy up repository.
-- Updated documents.
-
-* Mon 12 Jan 2009 Caius Chance <cchance at redhat.com>
-- Fixed copyright holder name typo for Sans Regular font (rhbz#479521).
-
-* Tue 09 Dec 2008 Caius Chance <cchance at redhat.com>
-- Changed cent sign glyph (U+00A2) to be coressed in Sans and Mono
- (rhbz#474522).
-
-* Wed 03 Dec 2008 Caius Chance <cchance at redhat.com>
-- Started 1.04.93.devel.
-- Fixed blurriness of U+03BC for Sans Regular font (rhbz#473481).
-- Fixed src tarball mis-inclusion of dist files in Makefile.
-
-* Fri 28 Nov 2008 Caius Chance <cchance at redhat.com>
-- Corrected version number in Makefile.
-- Fixed make target of source tarball.
-- Uploaded 1.04.92 source tarball to release area.
-
-* Wed 15 Oct 2008 Caius Chance <cchance at redhat.com>
-- Fixed blurred 'u' and 'W' for Sans Bold font (rhbz#463036).
-- Released as version 1.04.92
-
-* Wed 17 Sep 2008 Caius Chance <cchance at redhat.com>
-- Fixed missing hinting instructions for all Mono fonts (rhbz#460090).
-- Fixed missing hinting instructions for all Sans fonts (rhbz#460090).
-- Fixed missing hinting instructions for all Serif fonts (rhbz#460090).
-- Released as version 1.04.91
-
-* Tue 09 Sep 2008 Caius Chance <cchance at redhat.com>
-- Backed up all released files in ./dist directory.
-
-* Fri 05 Sep 2008 Caius Chance <cchance at redhat.com>
-- Fixed incorrect glyph points and missing hinting instructions for:
- Mono Bold Italic (up to U+2012) (rhbz#460090).
-
-* Mon 25 Aug 2008 Caius Chance <cchance at redhat.com>
-- Fixed incorrect glyph points and missing hinting instructions for:
- U+0079, U+03BC, U+0431, U+2010..2012, U+1114117 (rhbz#458592).
-- Released as version 1.04.90.
-
-* Thu 13 Jul 2008 Caius Chance <cchance at redhat.com>
-- Released as version 1.04.
-
-* Thu 12 Jun 2008 Caius Chance <cchance at redhat.com>
-- Released as version 1.04.beta2 (1.03.99).
-- Added ZIP package building for non-tar users.
-- rhbz#440992:
- - Created Romanian "T/t/S/s with comma below" (U+0218..021B) on all fonts.
- - Fixed "T/s with cedilla below" (U+0162/0163) on all fonts.
- - Created "Hyphen" and "Non-Breaking Hyphen" (U+2010..2011) on all fonts.
-
-* Wed 11 Jun 2008 Caius Chance <cchance at redhat.com>
-- Added last Version 1.03 from original manufacturer.
-- Renamed directory 'archive' to 'sandbox'.
-- Added directory description in hosting home directory.
-- Created ZIP packages for Version 1.03 and 1.04.beta.
-
-* Tue 04 Jun 2008 Caius Chance <cchance at redhat.com>
-- rhbz#440992:
- - Created "Hyphen" and "Non-Breaking Hyphen" (U+2010..2011) on Sans Regular.
-
-* Mon 03 Jun 2008 Caius Chance <cchance at redhat.com>
-- rhbz#440992:
- - Created Romanian "T/t/S/s with comma below" (U+0218..021B) on Sans Regular.
- - Fixed "T/s with cedilla below" (U+0162/0163) on Sans Regular.
-
-* Fri 30 May 2008 Caius Chance <cchance at redhat.com>
-- Release Version 1.04.beta (liberation-fonts-1_04_beta).
-
-* Thu 29 May 2008 Caius Chance <cchance at redhat.com>
-- Correct SFD version numbers in "TTF Info" categor for correct version
- number during export to TTFs.
-
-* Wed 28 May 2008 Caius Chance <cchance at redhat.com>
-- Reencoded with "Glyph Order" by FontForge.
-- Corrected font name for all Regular fonts.
-- Generated TTFs (experimantal, in "archive") with old stle kern and dummy
- DSIG table.
-- Updated README in 1.04b TTFs (experimental, in "archive").
-
-* Tue 27 May 2008 Caius Chance <cchance at redhat.com>
-- Fixed Unicode name mis-mapping of Sans and Serif TTF files.
-- Regenerate SFD files from Unicode name mis-mapping fixed Sans and Serif TTF
- files.
-
-* Mon 26 May 2008 Caius Chance <cchance at redhat.com>
-- Fixed Unicode name mis-mapping of Mono TTF files.
-- Regenerate SFD files from Unicode name mis-mapping fixed Mono TTF files.
-==========
-- Applied following patches submitted by Nicolas Spalinger
- <nicolas_spalinger sil org>:
- - We-need-versioned-tarballs.
- - Add-ignore-file-so-the-VCS-does-not-track-the-folder.
- - Adjust-path-for-various-Makefile-targets-subfolders.
- - Fix-versionning-mismatch-in-the-binary-font-metadata.
- - Add-some-description-and-extra-lines-to-the-build-ta.
- - Reword-and-restructure-maintainers-recommendations.
- - Some-rewording-of-the-readme-file.
-==========
-
-* Thu May 22 2008 Caius Chance <cchance at redhat.com>
-- Added latest (1.03) TTF files from Ascender. (in 'archive')
-
-* Fri May 16 2008 Caius Chance <cchance at redhat.com>
-- Change source tree as 'trunk', 'tags', 'branches'.
-==========
-- Applied following patches submitted by Nicolas Spalinger
- <nicolas_spalinger sil org>:
- - Add-more-information-about-the-upstream-designer.
- - Minor-typo-and-layout-fixes.
- - Adjust-fontforge-path-with-env-as-a-source-build.
-==========
-
-* Wed May 14 2008 Caius Chance <cchance at redhat.com>
-- Renamed target 'ttf' to 'build'.
-- Removed 'Re-Package' chapter from README and refine contents.
-- Changed AUTHORS contents.
-- Created maintainer documentation MAINTAINER.
-
-* Tue May 06 2008 Caius Chance <cchance at redhat.com>
-- Refined clean target.
-- Removed TTFs from git.
-
-* Fri May 02 2008 Caius Chance <cchance at redhat.com>
-- Imported into fedorahosted.org repository and be hosted.
- https://fedorahosted.org/liberation-fonts/
-- Modified source root directory name definition in Makefile.
-- Created 'dist' target for binary TTF tarball and 'src' for source tarball.
-- Corrected Regular fonts filenames.
-- Added TTF -> SFD make target.
-
-* Thu May 01 2008 Caius Chance <cchance at redhat.com>
-- Converted previous TTF files into SFD files to be open source.
-- Created fontforge SFD -> TTF scripts.
-- Created Makefile.
-- Added documentations: AUTHORS, ChangeLog, README.
-
-* Thu Apr 10 2008 Caius Chance <cchance at redhat.com>
-- Fixed exchanged and incomplete glyphs (from Ascender).
-- Repacked source tarball.
-- Released version 1.03.
-
-* Tue Mar 25 2008 Caius Chance <cchance at redhat.com>
-- Fixed alignment mismatch of dot accents (from Ascender).
-- Released version 1.02.
-
-* Mon Jan 14 2008 Caius Chance <cchance at redhat.com>
-- Updated new source tarball from Ascender.
-- Released version 1.0.
-
-* Thu Jun 14 2007 Caius Chance <cchance at redhat.com>
-- Updated new source tarball from Ascender.
Added: CometVisu/trunk/visu/designs/alaska/fonts/LICENSE.txt
===================================================================
--- CometVisu/trunk/visu/designs/alaska/fonts/LICENSE.txt (rev 0)
+++ CometVisu/trunk/visu/designs/alaska/fonts/LICENSE.txt 2011-12-26 22:05:37 UTC (rev 612)
@@ -0,0 +1,5 @@
+I have placed these fonts in the Public Domain. This is all 100% my
+own work. Usage is totally unrestricted. If you want to make
+derivative works for any purpose, please go ahead.
+
+-Thatcher Ulrich <tu...@tu...> http://tulrich.com
Property changes on: CometVisu/trunk/visu/designs/alaska/fonts/LICENSE.txt
___________________________________________________________________
Added: svn:executable
+ *
Deleted: CometVisu/trunk/visu/designs/alaska/fonts/License.txt
===================================================================
--- CometVisu/trunk/visu/designs/alaska/fonts/License.txt 2011-12-26 21:33:53 UTC (rev 611)
+++ CometVisu/trunk/visu/designs/alaska/fonts/License.txt 2011-12-26 22:05:37 UTC (rev 612)
@@ -1,19 +0,0 @@
-LICENSE AGREEMENT AND LIMITED PRODUCT WARRANTY
-LIBERATION FONT SOFTWARE
-
-This agreement governs the use of the Software and any updates to the Software, regardless of the delivery mechanism. Subject to the following terms, Red Hat, Inc. ("Red Hat") grants to the user ("Client") a license to this work pursuant to the GNU General Public License v.2 with the exceptions set forth below and such other terms as are set forth in this End User License Agreement.
-
- 1. The Software and License Exception. LIBERATION font software (the "Software") consists of TrueType-OpenType formatted font software for rendering LIBERATION typefaces in sans-serif, serif, and monospaced character styles. You are licensed to use, modify, copy, and distribute the Software pursuant to the GNU General Public License v.2 with the following exceptions:
-
- (a) As a special exception, if you create a document which uses this font, and embed this font or unaltered portions of this font into the document, this font does not by itself cause the resulting document to be covered by the GNU General Public License. This exception does not however invalidate any other reasons why the document might be covered by the GNU General Public License. If you modify this font, you may extend this exception to your version of the font, but you are not obligated to do so. If you do not wish to do so, delete this exception statement from your version.
-
- (b) As a further exception, any distribution of the object code of the Software in a physical product must provide you the right to access and modify the source code for the Software and to reinstall that modified version of the Software in object code form on the same physical product on which you received it.
-
- 2. Intellectual Property Rights. The Software and each of its components, including the source code, documentation, appearance, structure and organization are owned by Red Hat and others and are protected under copyright and other laws. Title to the Software and any component, or to any copy, modification, or merged portion shall remain with the aforementioned, subject to the applicable license. The "LIBERATION" trademark is a trademark of Red Hat, Inc. in the U.S. and other countries. This agreement does not permit Client to distribute modified versions of the Software using Red Hat's trademarks. If Client makes a redistribution of a modified version of the Software, then Client must modify the files names to remove any reference to the Red Hat trademarks and must not use the Red Hat trademarks in any way to reference or promote the modified Software.
-
- 3. Limited Warranty. To the maximum extent permitted under applicable law, the Software is provided and licensed "as is" without warranty of any kind, expressed or implied, including the implied warranties of merchantability, non-infringement or fitness for a particular purpose. Red Hat does not warrant that the functions contained in the Software will meet Client's requirements or that the operation of the Software will be entirely error free or appear precisely as described in the accompanying documentation.
-
- 4. Limitation of Remedies and Liability. To the maximum extent permitted by applicable law, Red Hat or any Red Hat authorized dealer will not be liable to Client for any incidental or consequential damages, including lost profits or lost savings arising out of the use or inability to use the Software, even if Red Hat or such dealer has been advised of the possibility of such damages.
-
- 5. General. If any provision of this agreement is held to be unenforceable, that shall not affect the enforceability of the remaining provisions. This agreement shall be governed by the laws of the State of North Carolina and of the United States, without regard to any conflict of laws provisions, except that the United Nations Convention on the International Sale of Goods shall not apply.
-Copyright © 2007 Red Hat, Inc. All rights reserved. LIBERATION is a trademark of Red Hat, Inc.
Deleted: CometVisu/trunk/visu/designs/alaska/fonts/README
===================================================================
--- CometVisu/trunk/visu/designs/alaska/fonts/README 2011-12-26 21:33:53 UTC (rev 611)
+++ CometVisu/trunk/visu/designs/alaska/fonts/README 2011-12-26 22:05:37 UTC (rev 612)
@@ -1,82 +0,0 @@
- 1. What's this?
- =================
-
- The Liberation Fonts is font collection which aims to provide document
- layout compatibility as usage of Times New Roman, Arial, Courier New.
-
-
- 2. Requirements
- =================
-
- * fontforge is installed.
- (http://fontforge.sourceforge.net)
-
-
- 3. Install
- ============
-
- 3.1 Decompress tarball
-
- You can extract the files by following command:
-
- $ tar zxvf liberation-fonts-[VERSION].tar.gz
-
- 3.2 Build from the source
-
- Change into directory liberation-fonts-[VERSION]/ and build from sources by
- following commands:
-
- $ cd liberation-fonts-[VERSION]
- $ make
-
- The built font files will be available in 'build' directory.
-
- 3.3 Install to system
-
- For Fedora, you could manually install the fonts by copying the TTFs to
- ~/.fonts for user wide usage, or to /usr/share/fonts/truetype/liberation
- for system-wide availability. Then, run "fc-cache" to let that cached.
-
- For other distributions, please check out corresponding documentation.
-
-
- 4. Usage
- ==========
-
- Simply select preferred liberation font in applications and start using.
-
-
- 5. License
- ============
-
- This font set had been released under GNU Public License version 2
- ("GPLv2") with exceptions.
-
- Please read file "COPYING" for GPLv2 license.
-
- Please read file "License.txt" for details of exceptions.
-
-
- 6. For Maintainers
- ====================
-
- Before packaging a new release based on a new source tarball, you have to
- update the version suffix in the Makefile:
-
- VER = [VERSION]
-
- Make sure that the defined version corresponds to the font software metadata
- which you can check with ftinfo/otfinfo or fontforge itself. It is highly
- recommended that file 'ChangeLog' is updated to reflect changes.
-
- Create a tarball with the following command:
-
- $ make dist
-
- The new versioned tarball will be available in the dist/ folder as
- 'liberation-fonts-[NEW_VERSION].tar.gz'.
-
- 7. Credits
- ============
-
- Please read file "AUTHORS" for list of contributors.
Deleted: CometVisu/trunk/visu/designs/alaska/fonts/TODO
===================================================================
--- CometVisu/trunk/visu/designs/alaska/fonts/TODO 2011-12-26 21:33:53 UTC (rev 611)
+++ CometVisu/trunk/visu/designs/alaska/fonts/TODO 2011-12-26 22:05:37 UTC (rev 612)
@@ -1,14 +0,0 @@
-Here are todo for next release
-
-1) resolving bug related with hinting
- - https://bugzilla.redhat.com/show_bug.cgi?id=606217
- - https://bugzilla.redhat.com/show_bug.cgi?id=591556
-2) shape improvement
- - https://bugzilla.redhat.com/show_bug.cgi?id=591559
- - https://bugzilla.redhat.com/show_bug.cgi?id=487581
-3) Ascent Descent Values Improvement
- - using absolute values instead of relative values in OS/2 table
-4) RFE: Add Greek Polytonic support to Liberation fonts
- - need some volunteer to add these shapes
- - https://bugzilla.redhat.com/show_bug.cgi?id=473842
-
Added: CometVisu/trunk/visu/designs/alaska/fonts/Tuffy.ttf
===================================================================
(Binary files differ)
Property changes on: CometVisu/trunk/visu/designs/alaska/fonts/Tuffy.ttf
___________________________________________________________________
Added: svn:executable
+ *
Added: svn:mime-type
+ application/octet-stream
Added: CometVisu/trunk/visu/designs/alaska/fonts/Tuffy_Bold.ttf
===================================================================
(Binary files differ)
Property changes on: CometVisu/trunk/visu/designs/alaska/fonts/Tuffy_Bold.ttf
___________________________________________________________________
Added: svn:executable
+ *
Added: svn:mime-type
+ application/octet-stream
Deleted: CometVisu/trunk/visu/designs/alaska/fonts/alaska_black_nocaps.ttf
===================================================================
(Binary files differ)
Deleted: CometVisu/trunk/visu/designs/alaska/fonts/alaska_light_nocaps.ttf
===================================================================
(Binary files differ)
Modified: CometVisu/trunk/visu/designs/alaska_slim/basic.css
===================================================================
--- CometVisu/trunk/visu/designs/alaska_slim/basic.css 2011-12-26 21:33:53 UTC (rev 611)
+++ CometVisu/trunk/visu/designs/alaska_slim/basic.css 2011-12-26 22:05:37 UTC (rev 612)
@@ -1,10 +1,10 @@
@import "colors.css";
-@font-face { font-family: alaska; src:url(fonts/alaska_light_nocaps.ttf); }
-@font-face { font-family: alaska; font-weight: bold; src:url(fonts/alaska_black_nocaps.ttf); }
+@font-face { font-family: Tuffy; src:url(../alaska/fonts/Tuffy.ttf); }
+@font-face { font-family: Tuffy; font-weight: bold; src:url(../alaska/fonts/Tuffy_Bold.ttf); }
body
{
- font-family: alaska,sans-serif;
+ font-family: Tuffy,sans-serif;
font-size: 5mm;
overflow: hidden;
margin:0;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-26 21:33:59
|
Revision: 611
http://openautomation.svn.sourceforge.net/openautomation/?rev=611&view=rev
Author: mayerch
Date: 2011-12-26 21:33:53 +0000 (Mon, 26 Dec 2011)
Log Message:
-----------
New feature: include "widget"
Modified Paths:
--------------
CometVisu/trunk/visu/designs/structure_pure.js
Modified: CometVisu/trunk/visu/designs/structure_pure.js
===================================================================
--- CometVisu/trunk/visu/designs/structure_pure.js 2011-12-26 15:46:24 UTC (rev 610)
+++ CometVisu/trunk/visu/designs/structure_pure.js 2011-12-26 21:33:53 UTC (rev 611)
@@ -128,6 +128,26 @@
content: true
});
+ this.addCreator('include', {
+ maturity: Maturity.development,
+ create: function( page, path, flavour ) {
+ var p = $.get( $(page).attr('src') );
+ var p = $.ajax({
+ url: $(page).attr('src'),
+ dataType: 'xml',
+ async: false
+ });
+ var child = (p.responseXML.childNodes[0]);
+ return create_pages( child, path , flavour );
+ },
+ attributes: {
+ src: { type: 'string', required: true }
+ },
+ elements: {
+ },
+ content: true
+ });
+
this.addCreator('group', {
maturity: Maturity.development,
create: function( page, path, flavour ) {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-26 15:46:30
|
Revision: 610
http://openautomation.svn.sourceforge.net/openautomation/?rev=610&view=rev
Author: mayerch
Date: 2011-12-26 15:46:24 +0000 (Mon, 26 Dec 2011)
Log Message:
-----------
Add missing function to read config file
Modified Paths:
--------------
wiregate/plugin/generic/Russound_RIO.pl
Modified: wiregate/plugin/generic/Russound_RIO.pl
===================================================================
--- wiregate/plugin/generic/Russound_RIO.pl 2011-12-26 15:26:55 UTC (rev 609)
+++ wiregate/plugin/generic/Russound_RIO.pl 2011-12-26 15:46:24 UTC (rev 610)
@@ -22,12 +22,40 @@
my $reset ; # set to 1 to reset the states, run script and change to 0 again
my $show_debug; # switches debug information that will be shown in the log
-
#############################################################################
# Do NOT change anything below!
#############################################################################
#############################################################################
+# Read config file in conf.d
+my $confFile = '/etc/wiregate/plugin/generic/conf.d/'.basename($plugname,'.pl').'.conf';
+if (! -f $confFile)
+{
+ plugin_log($plugname, " no conf file [$confFile] found.");
+}
+else
+{
+ plugin_log($plugname, " reading conf file [$confFile].") if( $show_debug > 1);
+ open(CONF, $confFile);
+ my @lines = <CONF>;
+ close($confFile);
+ my $result = eval("@lines");
+ if( $show_debug > 1 )
+ {
+ ($result) and plugin_log($plugname, "conf file [$confFile] returned result[$result]");
+ }
+ if ($@)
+ {
+ plugin_log($plugname, "conf file [$confFile] returned:") if( $show_debug > 1 );
+ my @parts = split(/\n/, $@);
+ if( $show_debug > 1 )
+ {
+ plugin_log($plugname, "--> $_") foreach (@parts);
+ }
+ }
+}
+
+#############################################################################
# External libraries:
use Net::Telnet ();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-26 15:27:02
|
Revision: 609
http://openautomation.svn.sourceforge.net/openautomation/?rev=609&view=rev
Author: mayerch
Date: 2011-12-26 15:26:55 +0000 (Mon, 26 Dec 2011)
Log Message:
-----------
Bug fix: numbers between -1 and 0 didn't show a negative sign when the format string was used.
Fix as shown in http://knx-user-forum.de/198589-post10.html
Modified Paths:
--------------
CometVisu/trunk/visu/lib/compatibility.js
Modified: CometVisu/trunk/visu/lib/compatibility.js
===================================================================
--- CometVisu/trunk/visu/lib/compatibility.js 2011-12-26 15:12:18 UTC (rev 608)
+++ CometVisu/trunk/visu/lib/compatibility.js 2011-12-26 15:26:55 UTC (rev 609)
@@ -48,7 +48,7 @@
min: match[6] || 0,
precision: match[8],
code: match[9] || '%',
- negative: parseInt(arguments[convCount]) < 0 ? true : false,
+ negative: parseFloat(arguments[convCount]) < 0 ? true : false,
argument: String(arguments[convCount])
};
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-26 15:12:25
|
Revision: 608
http://openautomation.svn.sourceforge.net/openautomation/?rev=608&view=rev
Author: mayerch
Date: 2011-12-26 15:12:18 +0000 (Mon, 26 Dec 2011)
Log Message:
-----------
Added new plugin: Russound communication via the RIO protocol
Added Paths:
-----------
wiregate/plugin/generic/Russound_RIO.pl
wiregate/plugin/generic/conf.d/Russound_RIO.conf_sample
Added: wiregate/plugin/generic/Russound_RIO.pl
===================================================================
--- wiregate/plugin/generic/Russound_RIO.pl (rev 0)
+++ wiregate/plugin/generic/Russound_RIO.pl 2011-12-26 15:12:18 UTC (rev 608)
@@ -0,0 +1,178 @@
+#############################################################################
+# Plugin: Russound RIO
+# V0.1 2011-12-26
+# Copyright: Christian Mayer (mail at ChristianMayer.de)
+# License: GPL (v3)
+#
+# Plugin for talking to the Russound multi room amplifiers via the RIO
+# protocoll over the IP interface
+#
+# Suggested settings:
+# ===================
+#
+#############################################################################
+
+#############################################################################
+# Configuration:
+# --> change values in the conf.d directory!
+my $IP_of_Russound;
+my $MAC_of_Russound;
+my $numzones;
+my $KNX_Start_Address;
+
+my $reset ; # set to 1 to reset the states, run script and change to 0 again
+my $show_debug; # switches debug information that will be shown in the log
+
+#############################################################################
+# Do NOT change anything below!
+#############################################################################
+
+#############################################################################
+# External libraries:
+use Net::Telnet ();
+
+#############################################################################
+# Constants:
+my $MAX_ZONES = 31;
+my $ZONES_PER_CONTROLLER = 6;
+
+#############################################################################
+# Collect log information
+my $retval = '';
+
+my $destReadable = $msg{'dst'};
+my $val = hex $msg{'data'};
+
+# Convert to numeric GA
+(my $a, my $b, my $c) = split(/\//, $KNX_Start_Address );
+my $knxstartaddress = (($a << 11) + ($b << 8) + $c);
+
+# Convert to numeric GA
+($a,$b,$c) = split(/\//, $destReadable );
+my $dest = (($a << 11) + ($b << 8) + $c);
+
+# Eigenen Aufruf-Zyklus ausschalten
+$plugin_info{$plugname.'_cycle'} = 0;
+
+# aboniere alle relevanten GAs
+for (my $zone=0;$zone<$numzones;$zone++)
+{
+ my $ctrl = int($zone/$ZONES_PER_CONTROLLER);
+ my $czone = int($zone%$ZONES_PER_CONTROLLER);
+ my $base = $knxstartaddress + 10 + ($czone*40) + ($ctrl*256);
+ for( my $i = 0; $i < 13; $i++ ) # iterate funcnames
+ {
+ my $a = $base + $i;
+ my $gastr = sprintf "%d/%d/%d", ($a >> 11) & 0xf, ($a >> 8) & 0x7, $a & 0xff;
+ $plugin_subscribe{$gastr}{$plugname} = 1;
+ }
+ for( my $i = 0; $i < 10; $i++ ) # iterate stateames
+ {
+ my $a = $base + $i + 20;
+ my $gastr = sprintf "%d/%d/%d", ($a >> 11) & 0xf, ($a >> 8) & 0x7, $a & 0xff;
+ $plugin_subscribe{$gastr}{$plugname} = 1;
+ }
+}
+
+$retval .= $msg{'apci'} . '->' . $msg{'dst'} . ';'. $msg{'data'} . ';' if $show_debug;
+
+#############################################################################
+# Main function
+if($msg{'apci'} eq "A_GroupValue_Write")
+{
+ # Transfere KNX Address to Russound Function similarly
+ # to the rusconnectd
+ my $func;
+ my $zone;
+ my $controller;
+ {
+ use integer;
+ $func = ($dest - $knxstartaddress) % 256;
+ $zone = ($func - 10) / 40;
+ $func = ($func - 10) % 40;
+ $controller = ($dest - $knxstartaddress) / 256;
+ }
+
+ sendrussFunc( $controller, $zone, $func, $val );
+}
+
+return $retval;
+
+#############################################################################
+# Helper funtions
+sub sendcmd
+{
+ my $cmd = shift;
+ my $t = new Net::Telnet (
+ Timeout => 10,
+ Host => $IP_of_Russound,
+ Port => 9621,
+ Prompt => '/^/',
+ Telnetmode => 0
+ );
+ $t->open();
+ $t->print( $cmd );
+ $t->close();
+ my $res = $t->getline();
+ $retval .= $cmd . '->' . $res if $show_debug;
+ return $res;
+}
+
+sub sendrussFunc
+{
+ my $controller = shift;
+ my $zone = shift;
+ my $func = shift;
+ my $val = shift;
+
+ my $cz = 'C[' . ($controller+1) . '].Z[' . ($zone+1) . ']';
+
+ if( -9 == $func ) #all zones
+ {
+ return 'Func ' . $func . ' not implemented or known';
+ } elsif( 0 == $func ) #power
+ {
+ `wakeonlan $MAC_of_Russound`; # just to be sure
+ sendcmd("EVENT $cz!ZoneOff") if( $val == 0 );
+ sendcmd("EVENT $cz!ZoneOn" ) if( $val == 1 );
+ } elsif( 1 == $func ) #src
+ {
+ my $mapped = $val + 1;
+ sendcmd("EVENT $cz!SelectSource $mapped");
+ } elsif( 2 == $func ) #volume
+ {
+ my $mapped = int( $val * 50/255 );
+ sendcmd("EVENT $cz!KeyPress Volume $mapped");
+ } elsif( 3 == $func ) #bass
+ {
+ my $mapped = $val > 10 ? $val-256 : $val;
+ sendcmd("SET $cz.bass=\"$mapped\"");
+ } elsif( 4 == $func ) #treb
+ {
+ my $mapped = $val > 10 ? $val-256 : $val;
+ sendcmd("SET $cz.treble=\"$mapped\"");
+ } elsif( 5 == $func ) #loud
+ {
+ return 'Func ' . $func . ' not implemented or known';
+ } elsif( 6 == $func ) #bal
+ {
+ my $mapped = $val > 10 ? $val-256 : $val;
+ sendcmd("SET $cz.balance=\"$mapped\"");
+ } elsif( 7 == $func ) #party
+ {
+ return 'Func ' . $func . ' not implemented or known';
+ } elsif( 8 == $func ) #dnd
+ {
+ return 'Func ' . $func . ' not implemented or known';
+ } elsif( 9 == $func ) #turnonvol
+ {
+ my $mapped = int( $val * 50/255 );
+ sendcmd("SET $cz.turnOnVolume=\"$mapped\"");
+ #TODO: 10 src cmd and 11 keypadcmd
+ } elsif( 12 == $func ) #volume relative up/down
+ {
+ return 'Func ' . $func . ' not implemented or known';
+ } else {
+ return 'Func ' . $func . ' not implemented or known';
+ }
+}
Added: wiregate/plugin/generic/conf.d/Russound_RIO.conf_sample
===================================================================
--- wiregate/plugin/generic/conf.d/Russound_RIO.conf_sample (rev 0)
+++ wiregate/plugin/generic/conf.d/Russound_RIO.conf_sample 2011-12-26 15:12:18 UTC (rev 608)
@@ -0,0 +1,22 @@
+#-----------------------------------------------------------------------------
+# ACHTUNG: Variablen duerfen nur im Plugin mit 'my' definiert werden,
+# 'my' hier nicht verwenden!
+#-----------------------------------------------------------------------------
+
+#############################################################################
+# Configuration:
+$IP_of_Russound = '192.168.0.118';
+$MAC_of_Russound = '00:21:xx:xx:xx:xx';
+$numzones = 6;
+$KNX_Start_Address = '10/1/0';
+
+$reset = 0; # set to 1 to reset the states, run script and change to 0 again
+$show_debug = 1; # switches debug information that will be shown in the log
+#############################################################################
+1;
+
+# emacs setting
+# ;;; Local Variables: ***
+# ;;; mode:perl ***
+# ;;; End: ***
+# vim: set filetype=perl expandtab tabstop=8 shiftwidth=2 autoindent smartindent:
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-21 15:56:39
|
Revision: 607
http://openautomation.svn.sourceforge.net/openautomation/?rev=607&view=rev
Author: mayerch
Date: 2011-12-21 15:56:28 +0000 (Wed, 21 Dec 2011)
Log Message:
-----------
A few helper functions to calculate the sun position out of a given date and geographic position to be able to set the correct lighting position.
Note: these formulas are very coarse. They should be refined later.
Modified Paths:
--------------
JSFloorPlan/trunk/src/jsfloorplan_example_helper.js
Modified: JSFloorPlan/trunk/src/jsfloorplan_example_helper.js
===================================================================
--- JSFloorPlan/trunk/src/jsfloorplan_example_helper.js 2011-12-20 21:20:36 UTC (rev 606)
+++ JSFloorPlan/trunk/src/jsfloorplan_example_helper.js 2011-12-21 15:56:28 UTC (rev 607)
@@ -519,4 +519,62 @@
j.show3D( roll, tilt );
}
-
+/**
+ * Calculate the position of the sun based on a simplified formula from
+ * http://en.wikipedia.org/wiki/Altitude_(astronomy)
+ * @class getSunPosition
+ * @constructor
+ *
+ * @param {Date} date
+ * @param {Number} latitude
+ * @param {Number} longitude
+ * @return {Object} azimuth, altitude
+ */
+function getSunPosition( date, latitude, longitude )
+{
+ /**
+ * Calculate the sun declination as described by
+ * http://en.wikipedia.org/wiki/Altitude_(astronomy)
+ * @method sunDeclination
+ * @private
+ * @param {Date} date
+ * @return {Number}
+ */
+ function sunDeclination( date )
+ {
+ var startOfYear = new Date( date.getUTCFullYear(), 1, 1, 0, 0, 0 );
+ var N = (date - startOfYear) /1000/60/60/24; // days since beginning of the year
+ return -23.45 * Math.PI / 180.0 * Math.cos( 2 * Math.PI * (N+10) / 365 );
+ }
+
+ /**
+ * Calculate the true hour angle as described by
+ * http://en.wikipedia.org/wiki/Altitude_(astronomy)
+ * @method trueHourAngle
+ * @private
+ * @param {Date} date
+ * @param {longitude} Longitude in degrees.
+ * @return {Number}
+ */
+ function trueHourAngle( date, longitude )
+ {
+ var T = date.getHours() + date.getMinutes() / 60;
+ T += longitude / 15 + date.getTimezoneOffset() / 60;
+ // + correction of daylight saving?!?
+ // + correction of Equation of Time - if left out the error is ~ +/-15min
+ return (12 - T) * 15 * Math.PI / 180;
+ }
+
+ var phi = latitude * Math.PI / 180;
+ var delta = sunDeclination( date );
+ var H = trueHourAngle( date, longitude );
+ var sin_a = Math.sin( phi ) * Math.sin( delta ) + Math.cos( phi ) * Math.cos( delta ) * Math.cos( H );
+ var cos_A_cos_a = Math.cos( phi ) * Math.sin( delta ) - Math.sin( phi ) * Math.cos( delta ) * Math.cos( H );
+ var sin_A_cos_a = -Math.cos( delta ) * Math.sin( H );
+
+ var azimuth = Math.atan2( sin_A_cos_a, cos_A_cos_a );
+ return {
+ azimuth: azimuth * 180/Math.PI,
+ altitude: Math.atan2( sin_a, azimuth ) * 180/Math.PI
+ };
+}
\ No newline at end of file
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2011-12-20 21:20:45
|
Revision: 606
http://openautomation.svn.sourceforge.net/openautomation/?rev=606&view=rev
Author: mayerch
Date: 2011-12-20 21:20:36 +0000 (Tue, 20 Dec 2011)
Log Message:
-----------
add relevant parts for a YUI Doc documentation
Added Paths:
-----------
JSFloorPlan/trunk/build/template/
JSFloorPlan/trunk/build/template/assets/
JSFloorPlan/trunk/build/template/assets/ac-js
JSFloorPlan/trunk/build/template/assets/api-js
JSFloorPlan/trunk/build/template/assets/api.css
JSFloorPlan/trunk/build/template/assets/bg_hd.gif
JSFloorPlan/trunk/build/template/assets/coordinate_system.png
JSFloorPlan/trunk/build/template/assets/reset-fonts-grids-min.css
JSFloorPlan/trunk/build/template/classmap.tmpl
JSFloorPlan/trunk/build/template/index.tmpl
JSFloorPlan/trunk/build/template/main.tmpl
Property Changed:
----------------
JSFloorPlan/trunk/
Property changes on: JSFloorPlan/trunk
___________________________________________________________________
Added: svn:ignore
+ parser
Added: JSFloorPlan/trunk/build/template/assets/ac-js
===================================================================
--- JSFloorPlan/trunk/build/template/assets/ac-js (rev 0)
+++ JSFloorPlan/trunk/build/template/assets/ac-js 2011-12-20 21:20:36 UTC (rev 606)
@@ -0,0 +1,178 @@
+(function() {
+
+ var Event=YAHOO.util.Event,
+ Dom=YAHOO.util.Dom,
+ oACDS, oAutoComp,
+ show = {
+ 'private': false,
+ 'protected': false,
+ 'deprecated': false
+ },
+
+ ITEM_TEMPLATE = '<em>{host}</em> <span>{name}</span>',
+ // ITEM_TEMPLATE = '<em>{host}</em> <span>{params}</span> <span>{name}</span>',
+ // ITEM_TEMPLATE = '<em>{host}</em> <span>{params}</span> <span>{name}</span><div>{description}</div>',
+ yuidoc = YAHOO.namespace('yuidoc'),
+ propdata,
+ initialized = false;
+
+yuidoc.init = function(altdata) {
+ yuidoc.initUI(altdata);
+};
+
+yuidoc.initUI = function(altdata) {
+
+ if (initialized) {
+ return;
+ }
+
+ propdata = ALL_YUI_PROPS || altdata;
+
+ //Checkboxes are available..
+ var handleClick = function(e) {
+ var id, checked = false;
+ if (YAHOO.lang.isString(e)) {
+ id = e;
+ } else {
+ var tar = Event.getTarget(e);
+ id = tar.id;
+ }
+ var el = Dom.get(id);
+ checked = el.checked;
+
+ var className = id;
+ if (checked) {
+ show[id.replace('show_', '')] = true;
+ Dom.addClass(document.body, className);
+ YAHOO.util.Cookie.setSub('yuidoc', id, 'checked');
+ } else {
+ show[id.replace('show_', '')] = false;
+ Dom.removeClass(document.body, className);
+ YAHOO.util.Cookie.setSub('yuidoc', id, '');
+ }
+ };
+
+ var checkCookie = function(id) {
+ var value = YAHOO.util.Cookie.getSub('yuidoc', id),
+ el = Dom.get(id), checked = (value === 'checked');;
+
+ el.checked = checked;
+ return checked;
+ };
+
+ var els = ['show_deprecated', 'show_protected', 'show_private'],
+ reapplyHash = false;
+
+ for (var i = 0; i < els.length; i++) {
+ Event.on(els[i], 'click', handleClick);
+ reapplyHash = checkCookie(els[i]) || reapplyHash;
+ handleClick(els[i]);
+ }
+
+ // If we dynamically show private/protected/etc items during
+ // load, we need to reapply anchors so that the search feature
+ // works correctly for items that are initially hidden.
+ if (reapplyHash) {
+ var dl = document.location, hash = dl.hash;
+ if (hash) {
+ dl.hash = hash;
+ }
+ }
+
+};
+
+//Starting the AutoComplete code
+ var getResults = function(query) {
+ var results = [];
+ if (query && query.length > 0) {
+ var q = query.toLowerCase();
+ for (var i=0, len=propdata.length; i<len; ++i) {
+ var prop = propdata[i];
+ if (!show['protected'] && prop.access == "protected") {
+ // skip
+ } else if (!show['private'] && prop.access == "private") {
+ // skip
+ } else if (!show['deprecated'] && prop.deprecated) {
+ // skip
+ } else {
+ var s = (prop.host + "." + prop.name).toLowerCase();
+ if (s.indexOf(q) > -1 ) {
+ results.push([query, prop]);
+ }
+ }
+ }
+ }
+
+ return results;
+ };
+
+ // Define Custom Event handlers
+ var myOnDataReturn = function(sType, aArgs) {
+ var oAutoComp = aArgs[0];
+ var query = aArgs[1];
+ var aResults = aArgs[2];
+
+ if(aResults.length == 0) {
+ if (query.length > 0) {
+ oAutoComp.setBody("<div id=\"resultsdefault\">Not found</div>");
+ }
+ }
+ };
+
+ var myOnItemSelect = function(sType, aArgs) {
+ var ac = aArgs[0];
+ var item = aArgs[2];
+ location.href = item[1].url;
+ };
+
+
+ Event.onAvailable("searchresults", function() {
+
+ // Instantiate JS Function DataSource
+ oACDS = new YAHOO.widget.DS_JSFunction(getResults);
+ oACDS.maxCacheEntries = 30;
+
+ // Instantiate AutoComplete
+ oAutoComp = new YAHOO.widget.AutoComplete('searchinput','searchresults', oACDS);
+ //oAutoComp.alwaysShowContainer = true;
+ oAutoComp.queryDelay = 0.2;
+ oAutoComp.maxResultsDisplayed = 200;
+ oAutoComp.minQueryLength = 0;
+ oAutoComp.formatResult = function(oResultItem, query) {
+ // var sMarkup = "<em>" + oResultItem[1].host + '</em> <span>' + oResultItem[1].name + '</span>';
+ // return sMarkup;
+ // return "<em>" + oResultItem[1].host + '</em> <span>' + oResultItem[1].name + '</span>';
+ return YAHOO.lang.substitute(ITEM_TEMPLATE, oResultItem[1]);
+ };
+
+ // Subscribe to Custom Events
+ oAutoComp.dataReturnEvent.subscribe(myOnDataReturn);
+ oAutoComp.itemSelectEvent.subscribe(myOnItemSelect);
+
+ // Set initial content in the container
+ oAutoComp.sendQuery(Dom.get("searchinput").value);
+
+ });
+
+ var validateForm = function() {
+ return false;
+ };
+
+ YAHOO.util.Event.onAvailable('classTab', function() {
+ var tabs = new YAHOO.widget.TabView('classTab');
+ });
+
+ /*
+ YAHOO.util.Event.onAvailable('codeTree', function() {
+ var tree1 = new YAHOO.widget.TreeView('codeTree');
+ tree1.render();
+ });
+ */
+
+ YAHOO.util.Event.onDOMReady(function() {
+ if (typeof ALL_YUI_PROPS != "undefined") {
+ YAHOO.yuidoc.initUI();
+ }
+ });
+
+})();
Added: JSFloorPlan/trunk/build/template/assets/api-js
===================================================================
--- JSFloorPlan/trunk/build/template/assets/api-js (rev 0)
+++ JSFloorPlan/trunk/build/template/assets/api-js 2011-12-20 21:20:36 UTC (rev 606)
@@ -0,0 +1,42 @@
+/*
+Copyright (c) 2009, Yahoo! Inc. All rights reserved.
+Code licensed under the BSD License:
+http://developer.yahoo.net/yui/license.txt
+version: 2.7.0
+*/
+if(typeof YAHOO=="undefined"||!YAHOO){var YAHOO={};}YAHOO.namespace=function(){var A=arguments,E=null,C,B,D;for(C=0;C<A.length;C=C+1){D=(""+A[C]).split(".");E=YAHOO;for(B=(D[0]=="YAHOO")?1:0;B<D.length;B=B+1){E[D[B]]=E[D[B]]||{};E=E[D[B]];}}return E;};YAHOO.log=function(D,A,C){var B=YAHOO.widget.Logger;if(B&&B.log){return B.log(D,A,C);}else{return false;}};YAHOO.register=function(A,E,D){var I=YAHOO.env.modules,B,H,G,F,C;if(!I[A]){I[A]={versions:[],builds:[]};}B=I[A];H=D.version;G=D.build;F=YAHOO.env.listeners;B.name=A;B.version=H;B.build=G;B.versions.push(H);B.builds.push(G);B.mainClass=E;for(C=0;C<F.length;C=C+1){F[C](B);}if(E){E.VERSION=H;E.BUILD=G;}else{YAHOO.log("mainClass is undefined for module "+A,"warn");}};YAHOO.env=YAHOO.env||{modules:[],listeners:[]};YAHOO.env.getVersion=function(A){return YAHOO.env.modules[A]||null;};YAHOO.env.ua=function(){var C={ie:0,opera:0,gecko:0,webkit:0,mobile:null,air:0,caja:0},B=navigator.userAgent,A;if((/KHTML/).test(B)){C.webkit=1;}A=B.match(/AppleWebKit\/([^\s]*)/);if(A&&A[1]){C.webkit=parseFloat(A[1]);if(/ Mobile\//.test(B)){C.mobile="Apple";}else{A=B.match(/NokiaN[^\/]*/);if(A){C.mobile=A[0];}}A=B.match(/AdobeAIR\/([^\s]*)/);if(A){C.air=A[0];}}if(!C.webkit){A=B.match(/Opera[\s\/]([^\s]*)/);if(A&&A[1]){C.opera=parseFloat(A[1]);A=B.match(/Opera Mini[^;]*/);if(A){C.mobile=A[0];}}else{A=B.match(/MSIE\s([^;]*)/);if(A&&A[1]){C.ie=parseFloat(A[1]);}else{A=B.match(/Gecko\/([^\s]*)/);if(A){C.gecko=1;A=B.match(/rv:([^\s\)]*)/);if(A&&A[1]){C.gecko=parseFloat(A[1]);}}}}}A=B.match(/Caja\/([^\s]*)/);if(A&&A[1]){C.caja=parseFloat(A[1]);}return C;}();(function(){YAHOO.namespace("util","widget","example");if("undefined"!==typeof YAHOO_config){var B=YAHOO_config.listener,A=YAHOO.env.listeners,D=true,C;if(B){for(C=0;C<A.length;C=C+1){if(A[C]==B){D=false;break;}}if(D){A.push(B);}}}})();YAHOO.lang=YAHOO.lang||{};(function(){var B=YAHOO.lang,F="[object Array]",C="[object Function]",A=Object.prototype,E=["toString","valueOf"],D={isArray:function(G){return A.toString.apply(G)===F;},isBoolean:function(G){return typeof G==="boolean";},isFunction:function(G){return A.toString.apply(G)===C;},isNull:function(G){return G===null;},isNumber:function(G){return typeof G==="number"&&isFinite(G);},isObject:function(G){return(G&&(typeof G==="object"||B.isFunction(G)))||false;},isString:function(G){return typeof G==="string";},isUndefined:function(G){return typeof G==="undefined";},_IEEnumFix:(YAHOO.env.ua.ie)?function(I,H){var G,K,J;for(G=0;G<E.length;G=G+1){K=E[G];J=H[K];if(B.isFunction(J)&&J!=A[K]){I[K]=J;}}}:function(){},extend:function(J,K,I){if(!K||!J){throw new Error("extend failed, please check that "+"all dependencies are included.");}var H=function(){},G;H.prototype=K.prototype;J.prototype=new H();J.prototype.constructor=J;J.superclass=K.prototype;if(K.prototype.constructor==A.constructor){K.prototype.constructor=K;}if(I){for(G in I){if(B.hasOwnProperty(I,G)){J.prototype[G]=I[G];}}B._IEEnumFix(J.prototype,I);}},augmentObject:function(K,J){if(!J||!K){throw new Error("Absorb failed, verify dependencies.");}var G=arguments,I,L,H=G[2];if(H&&H!==true){for(I=2;I<G.length;I=I+1){K[G[I]]=J[G[I]];}}else{for(L in J){if(H||!(L in K)){K[L]=J[L];}}B._IEEnumFix(K,J);}},augmentProto:function(J,I){if(!I||!J){throw new Error("Augment failed, verify dependencies.");}var G=[J.prototype,I.prototype],H;for(H=2;H<arguments.length;H=H+1){G.push(arguments[H]);}B.augmentObject.apply(this,G);},dump:function(G,L){var I,K,N=[],O="{...}",H="f(){...}",M=", ",J=" => ";if(!B.isObject(G)){return G+"";}else{if(G instanceof Date||("nodeType" in G&&"tagName" in G)){return G;}else{if(B.isFunction(G)){return H;}}}L=(B.isNumber(L))?L:3;if(B.isArray(G)){N.push("[");for(I=0,K=G.length;I<K;I=I+1){if(B.isObject(G[I])){N.push((L>0)?B.dump(G[I],L-1):O);}else{N.push(G[I]);}N.push(M);}if(N.length>1){N.pop();}N.push("]");}else{N.push("{");for(I in G){if(B.hasOwnProperty(G,I)){N.push(I+J);if(B.isObject(G[I])){N.push((L>0)?B.dump(G[I],L-1):O);}else{N.push(G[I]);}N.push(M);}}if(N.length>1){N.pop();}N.push("}");}return N.join("");},substitute:function(V,H,O){var L,K,J,R,S,U,Q=[],I,M="dump",P=" ",G="{",T="}",N;for(;;){L=V.lastIndexOf(G);if(L<0){break;}K=V.indexOf(T,L);if(L+1>=K){break;}I=V.substring(L+1,K);R=I;U=null;J=R.indexOf(P);if(J>-1){U=R.substring(J+1);R=R.substring(0,J);}S=H[R];if(O){S=O(R,S,U);}if(B.isObject(S)){if(B.isArray(S)){S=B.dump(S,parseInt(U,10));}else{U=U||"";N=U.indexOf(M);if(N>-1){U=U.substring(4);}if(S.toString===A.toString||N>-1){S=B.dump(S,parseInt(U,10));}else{S=S.toString();}}}else{if(!B.isString(S)&&!B.isNumber(S)){S="~-"+Q.length+"-~";Q[Q.length]=I;}}V=V.substring(0,L)+S+V.substring(K+1);}for(L=Q.length-1;L>=0;L=L-1){V=V.replace(new RegExp("~-"+L+"-~"),"{"+Q[L]+"}","g");}return V;},trim:function(G){try{return G.replace(/^\s+|\s+$/g,"");}catch(H){return G;}},merge:function(){var J={},H=arguments,G=H.length,I;for(I=0;I<G;I=I+1){B.augmentObject(J,H[I],true);}return J;},later:function(N,H,O,J,K){N=N||0;H=H||{};var I=O,M=J,L,G;if(B.isString(O)){I=H[O];}if(!I){throw new TypeError("method undefined");}if(!B.isArray(M)){M=[J];}L=function(){I.apply(H,M);};G=(K)?setInterval(L,N):setTimeout(L,N);return{interval:K,cancel:function(){if(this.interval){clearInterval(G);}else{clearTimeout(G);}}};},isValue:function(G){return(B.isObject(G)||B.isString(G)||B.isNumber(G)||B.isBoolean(G));}};B.hasOwnProperty=(A.hasOwnProperty)?function(G,H){return G&&G.hasOwnProperty(H);}:function(G,H){return !B.isUndefined(G[H])&&G.constructor.prototype[H]!==G[H];};D.augmentObject(B,D,true);YAHOO.util.Lang=B;B.augment=B.augmentProto;YAHOO.augment=B.augmentProto;YAHOO.extend=B.extend;})();YAHOO.register("yahoo",YAHOO,{version:"2.7.0",build:"1796"});(function(){YAHOO.env._id_counter=YAHOO.env._id_counter||0;var E=YAHOO.util,L=YAHOO.lang,m=YAHOO.env.ua,A=YAHOO.lang.trim,d={},h={},N=/^t(?:able|d|h)$/i,X=/color$/i,K=window.document,W=K.documentElement,e="ownerDocument",n="defaultView",v="documentElement",t="compatMode",b="offsetLeft",P="offsetTop",u="offsetParent",Z="parentNode",l="nodeType",C="tagName",O="scrollLeft",i="scrollTop",Q="getBoundingClientRect",w="getComputedStyle",a="currentStyle",M="CSS1Compat",c="BackCompat",g="class",F="className",J="",B=" ",s="(?:^|\\s)",k="(?= |$)",U="g",p="position",f="fixed",V="relative",j="left",o="top",r="medium",q="borderLeftWidth",R="borderTopWidth",D=m.opera,I=m.webkit,H=m.gecko,T=m.ie;E.Dom={CUSTOM_ATTRIBUTES:(!W.hasAttribute)?{"for":"htmlFor","class":F}:{"htmlFor":"for","className":g},get:function(y){var AA,Y,z,x,G;if(y){if(y[l]||y.item){return y;}if(typeof y==="string"){AA=y;y=K.getElementById(y);if(y&&y.id===AA){return y;}else{if(y&&K.all){y=null;Y=K.all[AA];for(x=0,G=Y.length;x<G;++x){if(Y[x].id===AA){return Y[x];}}}}return y;}if(y.DOM_EVENTS){y=y.get("element");}if("length" in y){z=[];for(x=0,G=y.length;x<G;++x){z[z.length]=E.Dom.get(y[x]);}return z;}return y;}return null;},getComputedStyle:function(G,Y){if(window[w]){return G[e][n][w](G,null)[Y];}else{if(G[a]){return E.Dom.IE_ComputedStyle.get(G,Y);}}},getStyle:function(G,Y){return E.Dom.batch(G,E.Dom._getStyle,Y);},_getStyle:function(){if(window[w]){return function(G,y){y=(y==="float")?y="cssFloat":E.Dom._toCamel(y);var x=G.style[y],Y;if(!x){Y=G[e][n][w](G,null);if(Y){x=Y[y];}}return x;};}else{if(W[a]){return function(G,y){var x;switch(y){case"opacity":x=100;try{x=G.filters["DXImageTransform.Microsoft.Alpha"].opacity;}catch(z){try{x=G.filters("alpha").opacity;}catch(Y){}}return x/100;case"float":y="styleFloat";default:y=E.Dom._toCamel(y);x=G[a]?G[a][y]:null;return(G.style[y]||x);}};}}}(),setStyle:function(G,Y,x){E.Dom.batch(G,E.Dom._setStyle,{prop:Y,val:x});},_setStyle:function(){if(T){return function(Y,G){var x=E.Dom._toCamel(G.prop),y=G.val;if(Y){switch(x){case"opacity":if(L.isString(Y.style.filter)){Y.style.filter="alpha(opacity="+y*100+")";if(!Y[a]||!Y[a].hasLayout){Y.style.zoom=1;}}break;case"float":x="styleFloat";default:Y.style[x]=y;}}else{}};}else{return function(Y,G){var x=E.Dom._toCamel(G.prop),y=G.val;if(Y){if(x=="float"){x="cssFloat";}Y.style[x]=y;}else{}};}}(),getXY:function(G){return E.Dom.batch(G,E.Dom._getXY);},_canPosition:function(G){return(E.Dom._getStyle(G,"display")!=="none"&&E.Dom._inDoc(G));},_getXY:function(){if(K[v][Q]){return function(y){var z,Y,AA,AF,AE,AD,AC,G,x,AB=Math.floor,AG=false;if(E.Dom._canPosition(y)){AA=y[Q]();AF=y[e];z=E.Dom.getDocumentScrollLeft(AF);Y=E.Dom.getDocumentScrollTop(AF);AG=[AB(AA[j]),AB(AA[o])];if(T&&m.ie<8){AE=2;AD=2;AC=AF[t];G=S(AF[v],q);x=S(AF[v],R);if(m.ie===6){if(AC!==c){AE=0;AD=0;}}if((AC==c)){if(G!==r){AE=parseInt(G,10);}if(x!==r){AD=parseInt(x,10);}}AG[0]-=AE;AG[1]-=AD;}if((Y||z)){AG[0]+=z;AG[1]+=Y;}AG[0]=AB(AG[0]);AG[1]=AB(AG[1]);}else{}return AG;};}else{return function(y){var x,Y,AA,AB,AC,z=false,G=y;if(E.Dom._canPosition(y)){z=[y[b],y[P]];x=E.Dom.getDocumentScrollLeft(y[e]);Y=E.Dom.getDocumentScrollTop(y[e]);AC=((H||m.webkit>519)?true:false);while((G=G[u])){z[0]+=G[b];z[1]+=G[P];if(AC){z=E.Dom._calcBorders(G,z);}}if(E.Dom._getStyle(y,p)!==f){G=y;while((G=G[Z])&&G[C]){AA=G[i];AB=G[O];if(H&&(E.Dom._getStyle(G,"overflow")!=="visible")){z=E.Dom._calcBorders(G,z);}if(AA||AB){z[0]-=AB;z[1]-=AA;}}z[0]+=x;z[1]+=Y;}else{if(D){z[0]-=x;z[1]-=Y;}else{if(I||H){z[0]+=x;z[1]+=Y;}}}z[0]=Math.floor(z[0]);z[1]=Math.floor(z[1]);}else{}return z;};}}(),getX:function(G){var Y=function(x){return E.Dom.getXY(x)[0];};return E.Dom.batch(G,Y,E.Dom,true);},getY:function(G){var Y=function(x){return E.Dom.getXY(x)[1];};return E.Dom.batch(G,Y,E.Dom,true);},setXY:function(G,x,Y){E.Dom.batch(G,E.Dom._setXY,{pos:x,noRetry:Y});},_setXY:function(G,z){var AA=E.Dom._getStyle(G,p),y=E.Dom.setStyle,AD=z.pos,Y=z.noRetry,AB=[parseInt(E.Dom.getComputedStyle(G,j),10),parseInt(E.Dom.getComputedStyle(G,o),10)],AC,x;if(AA=="static"){AA=V;y(G,p,AA);}AC=E.Dom._getXY(G);if(!AD||AC===false){return false;}if(isNaN(AB[0])){AB[0]=(AA==V)?0:G[b];}if(isNaN(AB[1])){AB[1]=(AA==V)?0:G[P];}if(AD[0]!==null){y(G,j,AD[0]-AC[0]+AB[0]+"px");}if(AD[1]!==null){y(G,o,AD[1]-AC[1]+AB[1]+"px");}if(!Y){x=E.Dom._getXY(G);if((AD[0]!==null&&x[0]!=AD[0])||(AD[1]!==null&&x[1]!=AD[1])){E.Dom._setXY(G,{pos:AD,noRetry:true});}}},setX:function(Y,G){E.Dom.setXY(Y,[G,null]);},setY:function(G,Y){E.Dom.setXY(G,[null,Y]);},getRegion:function(G){var Y=function(x){var y=false;if(E.Dom._canPosition(x)){y=E.Region.getRegion(x);}else{}return y;};return E.Dom.batch(G,Y,E.Dom,true);},getClientWidth:function(){return E.Dom.getViewportWidth();},getClientHeight:function(){return E.Dom.getViewportHeight();},getElementsByClassName:function(AB,AF,AC,AE,x,AD){AB=L.trim(AB);AF=AF||"*";AC=(AC)?E.Dom.get(AC):null||K;if(!AC){return[];}var Y=[],G=AC.getElementsByTagName(AF),z=E.Dom.hasClass;for(var y=0,AA=G.length;y<AA;++y){if(z(G[y],AB)){Y[Y.length]=G[y];}}if(AE){E.Dom.batch(Y,AE,x,AD);}return Y;},hasClass:function(Y,G){return E.Dom.batch(Y,E.Dom._hasClass,G);},_hasClass:function(x,Y){var G=false,y;if(x&&Y){y=E.Dom.getAttribute(x,F)||J;if(Y.exec){G=Y.test(y);}else{G=Y&&(B+y+B).indexOf(B+Y+B)>-1;}}else{}return G;},addClass:function(Y,G){return E.Dom.batch(Y,E.Dom._addClass,G);},_addClass:function(x,Y){var G=false,y;if(x&&Y){y=E.Dom.getAttribute(x,F)||J;if(!E.Dom._hasClass(x,Y)){E.Dom.setAttribute(x,F,A(y+B+Y));G=true;}}else{}return G;},removeClass:function(Y,G){return E.Dom.batch(Y,E.Dom._removeClass,G);},_removeClass:function(y,x){var Y=false,AA,z,G;if(y&&x){AA=E.Dom.getAttribute(y,F)||J;E.Dom.setAttribute(y,F,AA.replace(E.Dom._getClassRegex(x),J));z=E.Dom.getAttribute(y,F);if(AA!==z){E.Dom.setAttribute(y,F,A(z));Y=true;if(E.Dom.getAttribute(y,F)===""){G=(y.hasAttribute&&y.hasAttribute(g))?g:F;y.removeAttribute(G);}}}else{}return Y;},replaceClass:function(x,Y,G){return E.Dom.batch(x,E.Dom._replaceClass,{from:Y,to:G});
+},_replaceClass:function(y,x){var Y,AB,AA,G=false,z;if(y&&x){AB=x.from;AA=x.to;if(!AA){G=false;}else{if(!AB){G=E.Dom._addClass(y,x.to);}else{if(AB!==AA){z=E.Dom.getAttribute(y,F)||J;Y=(B+z.replace(E.Dom._getClassRegex(AB),B+AA)).split(E.Dom._getClassRegex(AA));Y.splice(1,0,B+AA);E.Dom.setAttribute(y,F,A(Y.join(J)));G=true;}}}}else{}return G;},generateId:function(G,x){x=x||"yui-gen";var Y=function(y){if(y&&y.id){return y.id;}var z=x+YAHOO.env._id_counter++;if(y){if(y[e].getElementById(z)){return E.Dom.generateId(y,z+x);}y.id=z;}return z;};return E.Dom.batch(G,Y,E.Dom,true)||Y.apply(E.Dom,arguments);},isAncestor:function(Y,x){Y=E.Dom.get(Y);x=E.Dom.get(x);var G=false;if((Y&&x)&&(Y[l]&&x[l])){if(Y.contains&&Y!==x){G=Y.contains(x);}else{if(Y.compareDocumentPosition){G=!!(Y.compareDocumentPosition(x)&16);}}}else{}return G;},inDocument:function(G,Y){return E.Dom._inDoc(E.Dom.get(G),Y);},_inDoc:function(Y,x){var G=false;if(Y&&Y[C]){x=x||Y[e];G=E.Dom.isAncestor(x[v],Y);}else{}return G;},getElementsBy:function(Y,AF,AB,AD,y,AC,AE){AF=AF||"*";AB=(AB)?E.Dom.get(AB):null||K;if(!AB){return[];}var x=[],G=AB.getElementsByTagName(AF);for(var z=0,AA=G.length;z<AA;++z){if(Y(G[z])){if(AE){x=G[z];break;}else{x[x.length]=G[z];}}}if(AD){E.Dom.batch(x,AD,y,AC);}return x;},getElementBy:function(x,G,Y){return E.Dom.getElementsBy(x,G,Y,null,null,null,true);},batch:function(x,AB,AA,z){var y=[],Y=(z)?AA:window;x=(x&&(x[C]||x.item))?x:E.Dom.get(x);if(x&&AB){if(x[C]||x.length===undefined){return AB.call(Y,x,AA);}for(var G=0;G<x.length;++G){y[y.length]=AB.call(Y,x[G],AA);}}else{return false;}return y;},getDocumentHeight:function(){var Y=(K[t]!=M||I)?K.body.scrollHeight:W.scrollHeight,G=Math.max(Y,E.Dom.getViewportHeight());return G;},getDocumentWidth:function(){var Y=(K[t]!=M||I)?K.body.scrollWidth:W.scrollWidth,G=Math.max(Y,E.Dom.getViewportWidth());return G;},getViewportHeight:function(){var G=self.innerHeight,Y=K[t];if((Y||T)&&!D){G=(Y==M)?W.clientHeight:K.body.clientHeight;}return G;},getViewportWidth:function(){var G=self.innerWidth,Y=K[t];if(Y||T){G=(Y==M)?W.clientWidth:K.body.clientWidth;}return G;},getAncestorBy:function(G,Y){while((G=G[Z])){if(E.Dom._testElement(G,Y)){return G;}}return null;},getAncestorByClassName:function(Y,G){Y=E.Dom.get(Y);if(!Y){return null;}var x=function(y){return E.Dom.hasClass(y,G);};return E.Dom.getAncestorBy(Y,x);},getAncestorByTagName:function(Y,G){Y=E.Dom.get(Y);if(!Y){return null;}var x=function(y){return y[C]&&y[C].toUpperCase()==G.toUpperCase();};return E.Dom.getAncestorBy(Y,x);},getPreviousSiblingBy:function(G,Y){while(G){G=G.previousSibling;if(E.Dom._testElement(G,Y)){return G;}}return null;},getPreviousSibling:function(G){G=E.Dom.get(G);if(!G){return null;}return E.Dom.getPreviousSiblingBy(G);},getNextSiblingBy:function(G,Y){while(G){G=G.nextSibling;if(E.Dom._testElement(G,Y)){return G;}}return null;},getNextSibling:function(G){G=E.Dom.get(G);if(!G){return null;}return E.Dom.getNextSiblingBy(G);},getFirstChildBy:function(G,x){var Y=(E.Dom._testElement(G.firstChild,x))?G.firstChild:null;return Y||E.Dom.getNextSiblingBy(G.firstChild,x);},getFirstChild:function(G,Y){G=E.Dom.get(G);if(!G){return null;}return E.Dom.getFirstChildBy(G);},getLastChildBy:function(G,x){if(!G){return null;}var Y=(E.Dom._testElement(G.lastChild,x))?G.lastChild:null;return Y||E.Dom.getPreviousSiblingBy(G.lastChild,x);},getLastChild:function(G){G=E.Dom.get(G);return E.Dom.getLastChildBy(G);},getChildrenBy:function(Y,y){var x=E.Dom.getFirstChildBy(Y,y),G=x?[x]:[];E.Dom.getNextSiblingBy(x,function(z){if(!y||y(z)){G[G.length]=z;}return false;});return G;},getChildren:function(G){G=E.Dom.get(G);if(!G){}return E.Dom.getChildrenBy(G);},getDocumentScrollLeft:function(G){G=G||K;return Math.max(G[v].scrollLeft,G.body.scrollLeft);},getDocumentScrollTop:function(G){G=G||K;return Math.max(G[v].scrollTop,G.body.scrollTop);},insertBefore:function(Y,G){Y=E.Dom.get(Y);G=E.Dom.get(G);if(!Y||!G||!G[Z]){return null;}return G[Z].insertBefore(Y,G);},insertAfter:function(Y,G){Y=E.Dom.get(Y);G=E.Dom.get(G);if(!Y||!G||!G[Z]){return null;}if(G.nextSibling){return G[Z].insertBefore(Y,G.nextSibling);}else{return G[Z].appendChild(Y);}},getClientRegion:function(){var x=E.Dom.getDocumentScrollTop(),Y=E.Dom.getDocumentScrollLeft(),y=E.Dom.getViewportWidth()+Y,G=E.Dom.getViewportHeight()+x;return new E.Region(x,y,G,Y);},setAttribute:function(Y,G,x){G=E.Dom.CUSTOM_ATTRIBUTES[G]||G;Y.setAttribute(G,x);},getAttribute:function(Y,G){G=E.Dom.CUSTOM_ATTRIBUTES[G]||G;return Y.getAttribute(G);},_toCamel:function(Y){var x=d;function G(y,z){return z.toUpperCase();}return x[Y]||(x[Y]=Y.indexOf("-")===-1?Y:Y.replace(/-([a-z])/gi,G));},_getClassRegex:function(Y){var G;if(Y!==undefined){if(Y.exec){G=Y;}else{G=h[Y];if(!G){Y=Y.replace(E.Dom._patterns.CLASS_RE_TOKENS,"\\$1");G=h[Y]=new RegExp(s+Y+k,U);}}}return G;},_patterns:{ROOT_TAG:/^body|html$/i,CLASS_RE_TOKENS:/([\.\(\)\^\$\*\+\?\|\[\]\{\}])/g},_testElement:function(G,Y){return G&&G[l]==1&&(!Y||Y(G));},_calcBorders:function(x,y){var Y=parseInt(E.Dom[w](x,R),10)||0,G=parseInt(E.Dom[w](x,q),10)||0;if(H){if(N.test(x[C])){Y=0;G=0;}}y[0]+=G;y[1]+=Y;return y;}};var S=E.Dom[w];if(m.opera){E.Dom[w]=function(Y,G){var x=S(Y,G);if(X.test(G)){x=E.Dom.Color.toRGB(x);}return x;};}if(m.webkit){E.Dom[w]=function(Y,G){var x=S(Y,G);if(x==="rgba(0, 0, 0, 0)"){x="transparent";}return x;};}})();YAHOO.util.Region=function(C,D,A,B){this.top=C;this.y=C;this[1]=C;this.right=D;this.bottom=A;this.left=B;this.x=B;this[0]=B;this.width=this.right-this.left;this.height=this.bottom-this.top;};YAHOO.util.Region.prototype.contains=function(A){return(A.left>=this.left&&A.right<=this.right&&A.top>=this.top&&A.bottom<=this.bottom);};YAHOO.util.Region.prototype.getArea=function(){return((this.bottom-this.top)*(this.right-this.left));};YAHOO.util.Region.prototype.intersect=function(E){var C=Math.max(this.top,E.top),D=Math.min(this.right,E.right),A=Math.min(this.bottom,E.bottom),B=Math.max(this.left,E.left);if(A>=C&&D>=B){return new YAHOO.util.Region(C,D,A,B);
+}else{return null;}};YAHOO.util.Region.prototype.union=function(E){var C=Math.min(this.top,E.top),D=Math.max(this.right,E.right),A=Math.max(this.bottom,E.bottom),B=Math.min(this.left,E.left);return new YAHOO.util.Region(C,D,A,B);};YAHOO.util.Region.prototype.toString=function(){return("Region {"+"top: "+this.top+", right: "+this.right+", bottom: "+this.bottom+", left: "+this.left+", height: "+this.height+", width: "+this.width+"}");};YAHOO.util.Region.getRegion=function(D){var F=YAHOO.util.Dom.getXY(D),C=F[1],E=F[0]+D.offsetWidth,A=F[1]+D.offsetHeight,B=F[0];return new YAHOO.util.Region(C,E,A,B);};YAHOO.util.Point=function(A,B){if(YAHOO.lang.isArray(A)){B=A[1];A=A[0];}YAHOO.util.Point.superclass.constructor.call(this,B,A,B,A);};YAHOO.extend(YAHOO.util.Point,YAHOO.util.Region);(function(){var B=YAHOO.util,A="clientTop",F="clientLeft",J="parentNode",K="right",W="hasLayout",I="px",U="opacity",L="auto",D="borderLeftWidth",G="borderTopWidth",P="borderRightWidth",V="borderBottomWidth",S="visible",Q="transparent",N="height",E="width",H="style",T="currentStyle",R=/^width|height$/,O=/^(\d[.\d]*)+(em|ex|px|gd|rem|vw|vh|vm|ch|mm|cm|in|pt|pc|deg|rad|ms|s|hz|khz|%){1}?/i,M={get:function(X,Z){var Y="",a=X[T][Z];if(Z===U){Y=B.Dom.getStyle(X,U);}else{if(!a||(a.indexOf&&a.indexOf(I)>-1)){Y=a;}else{if(B.Dom.IE_COMPUTED[Z]){Y=B.Dom.IE_COMPUTED[Z](X,Z);}else{if(O.test(a)){Y=B.Dom.IE.ComputedStyle.getPixel(X,Z);}else{Y=a;}}}}return Y;},getOffset:function(Z,e){var b=Z[T][e],X=e.charAt(0).toUpperCase()+e.substr(1),c="offset"+X,Y="pixel"+X,a="",d;if(b==L){d=Z[c];if(d===undefined){a=0;}a=d;if(R.test(e)){Z[H][e]=d;if(Z[c]>d){a=d-(Z[c]-d);}Z[H][e]=L;}}else{if(!Z[H][Y]&&!Z[H][e]){Z[H][e]=b;}a=Z[H][Y];}return a+I;},getBorderWidth:function(X,Z){var Y=null;if(!X[T][W]){X[H].zoom=1;}switch(Z){case G:Y=X[A];break;case V:Y=X.offsetHeight-X.clientHeight-X[A];break;case D:Y=X[F];break;case P:Y=X.offsetWidth-X.clientWidth-X[F];break;}return Y+I;},getPixel:function(Y,X){var a=null,b=Y[T][K],Z=Y[T][X];Y[H][K]=Z;a=Y[H].pixelRight;Y[H][K]=b;return a+I;},getMargin:function(Y,X){var Z;if(Y[T][X]==L){Z=0+I;}else{Z=B.Dom.IE.ComputedStyle.getPixel(Y,X);}return Z;},getVisibility:function(Y,X){var Z;while((Z=Y[T])&&Z[X]=="inherit"){Y=Y[J];}return(Z)?Z[X]:S;},getColor:function(Y,X){return B.Dom.Color.toRGB(Y[T][X])||Q;},getBorderColor:function(Y,X){var Z=Y[T],a=Z[X]||Z.color;return B.Dom.Color.toRGB(B.Dom.Color.toHex(a));}},C={};C.top=C.right=C.bottom=C.left=C[E]=C[N]=M.getOffset;C.color=M.getColor;C[G]=C[P]=C[V]=C[D]=M.getBorderWidth;C.marginTop=C.marginRight=C.marginBottom=C.marginLeft=M.getMargin;C.visibility=M.getVisibility;C.borderColor=C.borderTopColor=C.borderRightColor=C.borderBottomColor=C.borderLeftColor=M.getBorderColor;B.Dom.IE_COMPUTED=C;B.Dom.IE_ComputedStyle=M;})();(function(){var C="toString",A=parseInt,B=RegExp,D=YAHOO.util;D.Dom.Color={KEYWORDS:{black:"000",silver:"c0c0c0",gray:"808080",white:"fff",maroon:"800000",red:"f00",purple:"800080",fuchsia:"f0f",green:"008000",lime:"0f0",olive:"808000",yellow:"ff0",navy:"000080",blue:"00f",teal:"008080",aqua:"0ff"},re_RGB:/^rgb\(([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\)$/i,re_hex:/^#?([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})$/i,re_hex3:/([0-9A-F])/gi,toRGB:function(E){if(!D.Dom.Color.re_RGB.test(E)){E=D.Dom.Color.toHex(E);}if(D.Dom.Color.re_hex.exec(E)){E="rgb("+[A(B.$1,16),A(B.$2,16),A(B.$3,16)].join(", ")+")";}return E;},toHex:function(H){H=D.Dom.Color.KEYWORDS[H]||H;if(D.Dom.Color.re_RGB.exec(H)){var G=(B.$1.length===1)?"0"+B.$1:Number(B.$1),F=(B.$2.length===1)?"0"+B.$2:Number(B.$2),E=(B.$3.length===1)?"0"+B.$3:Number(B.$3);H=[G[C](16),F[C](16),E[C](16)].join("");}if(H.length<6){H=H.replace(D.Dom.Color.re_hex3,"$1$1");}if(H!=="transparent"&&H.indexOf("#")<0){H="#"+H;}return H.toLowerCase();}};}());YAHOO.register("dom",YAHOO.util.Dom,{version:"2.7.0",build:"1796"});YAHOO.util.CustomEvent=function(D,C,B,A){this.type=D;this.scope=C||window;this.silent=B;this.signature=A||YAHOO.util.CustomEvent.LIST;this.subscribers=[];if(!this.silent){}var E="_YUICEOnSubscribe";if(D!==E){this.subscribeEvent=new YAHOO.util.CustomEvent(E,this,true);}this.lastError=null;};YAHOO.util.CustomEvent.LIST=0;YAHOO.util.CustomEvent.FLAT=1;YAHOO.util.CustomEvent.prototype={subscribe:function(A,B,C){if(!A){throw new Error("Invalid callback for subscriber to '"+this.type+"'");}if(this.subscribeEvent){this.subscribeEvent.fire(A,B,C);}this.subscribers.push(new YAHOO.util.Subscriber(A,B,C));},unsubscribe:function(D,F){if(!D){return this.unsubscribeAll();}var E=false;for(var B=0,A=this.subscribers.length;B<A;++B){var C=this.subscribers[B];if(C&&C.contains(D,F)){this._delete(B);E=true;}}return E;},fire:function(){this.lastError=null;var K=[],E=this.subscribers.length;if(!E&&this.silent){return true;}var I=[].slice.call(arguments,0),G=true,D,J=false;if(!this.silent){}var C=this.subscribers.slice(),A=YAHOO.util.Event.throwErrors;for(D=0;D<E;++D){var M=C[D];if(!M){J=true;}else{if(!this.silent){}var L=M.getScope(this.scope);if(this.signature==YAHOO.util.CustomEvent.FLAT){var B=null;if(I.length>0){B=I[0];}try{G=M.fn.call(L,B,M.obj);}catch(F){this.lastError=F;if(A){throw F;}}}else{try{G=M.fn.call(L,this.type,I,M.obj);}catch(H){this.lastError=H;if(A){throw H;}}}if(false===G){if(!this.silent){}break;}}}return(G!==false);},unsubscribeAll:function(){var A=this.subscribers.length,B;for(B=A-1;B>-1;B--){this._delete(B);}this.subscribers=[];return A;},_delete:function(A){var B=this.subscribers[A];if(B){delete B.fn;delete B.obj;}this.subscribers.splice(A,1);},toString:function(){return"CustomEvent: "+"'"+this.type+"', "+"context: "+this.scope;}};YAHOO.util.Subscriber=function(A,B,C){this.fn=A;this.obj=YAHOO.lang.isUndefined(B)?null:B;this.overrideContext=C;};YAHOO.util.Subscriber.prototype.getScope=function(A){if(this.overrideContext){if(this.overrideContext===true){return this.obj;}else{return this.overrideContext;}}return A;};YAHOO.util.Subscriber.prototype.contains=function(A,B){if(B){return(this.fn==A&&this.obj==B);}else{return(this.fn==A);}};YAHOO.util.Subscriber.prototype.toString=function(){return"Subscriber { obj: "+this.obj+", overrideContext: "+(this.overrideContext||"no")+" }";};if(!YAHOO.util.Event){YAHOO.util.Event=function(){var H=false;var I=[];var J=[];var G=[];var E=[];var C=0;var F=[];var B=[];var A=0;var D={63232:38,63233:40,63234:37,63235:39,63276:33,63277:34,25:9};var K=YAHOO.env.ua.ie?"focusin":"focus";var L=YAHOO.env.ua.ie?"focusout":"blur";return{POLL_RETRYS:2000,POLL_INTERVAL:20,EL:0,TYPE:1,FN:2,WFN:3,UNLOAD_OBJ:3,ADJ_SCOPE:4,OBJ:5,OVERRIDE:6,lastError:null,isSafari:YAHOO.env.ua.webkit,webkit:YAHOO.env.ua.webkit,isIE:YAHOO.env.ua.ie,_interval:null,_dri:null,DOMReady:false,throwErrors:false,startInterval:function(){if(!this._interval){var M=this;var N=function(){M._tryPreloadAttach();};this._interval=setInterval(N,this.POLL_INTERVAL);}},onAvailable:function(S,O,Q,R,P){var M=(YAHOO.lang.isString(S))?[S]:S;for(var N=0;N<M.length;N=N+1){F.push({id:M[N],fn:O,obj:Q,overrideContext:R,checkReady:P});}C=this.POLL_RETRYS;this.startInterval();},onContentReady:function(P,M,N,O){this.onAvailable(P,M,N,O,true);},onDOMReady:function(M,N,O){if(this.DOMReady){setTimeout(function(){var P=window;if(O){if(O===true){P=N;}else{P=O;}}M.call(P,"DOMReady",[],N);},0);}else{this.DOMReadyEvent.subscribe(M,N,O);}},_addListener:function(O,M,Y,S,W,b){if(!Y||!Y.call){return false;}if(this._isValidCollection(O)){var Z=true;for(var T=0,V=O.length;T<V;++T){Z=this.on(O[T],M,Y,S,W)&&Z;}return Z;}else{if(YAHOO.lang.isString(O)){var R=this.getEl(O);if(R){O=R;}else{this.onAvailable(O,function(){YAHOO.util.Event.on(O,M,Y,S,W);});return true;}}}if(!O){return false;}if("unload"==M&&S!==this){J[J.length]=[O,M,Y,S,W];return true;}var N=O;if(W){if(W===true){N=S;}else{N=W;}}var P=function(c){return Y.call(N,YAHOO.util.Event.getEvent(c,O),S);};var a=[O,M,Y,P,N,S,W];var U=I.length;I[U]=a;if(this.useLegacyEvent(O,M)){var Q=this.getLegacyIndex(O,M);if(Q==-1||O!=G[Q][0]){Q=G.length;B[O.id+M]=Q;G[Q]=[O,M,O["on"+M]];E[Q]=[];O["on"+M]=function(c){YAHOO.util.Event.fireLegacyEvent(YAHOO.util.Event.getEvent(c),Q);};}E[Q].push(a);}else{try{this._simpleAdd(O,M,P,b);}catch(X){this.lastError=X;this.removeListener(O,M,Y);return false;}}return true;},addListener:function(N,Q,M,O,P){return this._addListener(N,Q,M,O,P,false);},addFocusListener:function(N,M,O,P){return this._addListener(N,K,M,O,P,true);},removeFocusListener:function(N,M){return this.removeListener(N,K,M);},addBlurListener:function(N,M,O,P){return this._addListener(N,L,M,O,P,true);},removeBlurListener:function(N,M){return this.removeListener(N,L,M);},fireLegacyEvent:function(R,P){var T=true,M,V,U,N,S;V=E[P].slice();for(var O=0,Q=V.length;O<Q;++O){U=V[O];if(U&&U[this.WFN]){N=U[this.ADJ_SCOPE];S=U[this.WFN].call(N,R);T=(T&&S);}}M=G[P];if(M&&M[2]){M[2](R);}return T;},getLegacyIndex:function(N,O){var M=this.generateId(N)+O;if(typeof B[M]=="undefined"){return -1;}else{return B[M];}},useLegacyEvent:function(M,N){return(this.webkit&&this.webkit<419&&("click"==N||"dblclick"==N));},removeListener:function(N,M,V){var Q,T,X;if(typeof N=="string"){N=this.getEl(N);}else{if(this._isValidCollection(N)){var W=true;for(Q=N.length-1;Q>-1;Q--){W=(this.removeListener(N[Q],M,V)&&W);}return W;}}if(!V||!V.call){return this.purgeElement(N,false,M);}if("unload"==M){for(Q=J.length-1;Q>-1;Q--){X=J[Q];if(X&&X[0]==N&&X[1]==M&&X[2]==V){J.splice(Q,1);return true;}}return false;}var R=null;var S=arguments[3];if("undefined"===typeof S){S=this._getCacheIndex(N,M,V);}if(S>=0){R=I[S];}if(!N||!R){return false;}if(this.useLegacyEvent(N,M)){var P=this.getLegacyIndex(N,M);var O=E[P];if(O){for(Q=0,T=O.length;Q<T;++Q){X=O[Q];if(X&&X[this.EL]==N&&X[this.TYPE]==M&&X[this.FN]==V){O.splice(Q,1);break;}}}}else{try{this._simpleRemove(N,M,R[this.WFN],false);}catch(U){this.lastError=U;return false;}}delete I[S][this.WFN];delete I[S][this.FN];
+I.splice(S,1);return true;},getTarget:function(O,N){var M=O.target||O.srcElement;return this.resolveTextNode(M);},resolveTextNode:function(N){try{if(N&&3==N.nodeType){return N.parentNode;}}catch(M){}return N;},getPageX:function(N){var M=N.pageX;if(!M&&0!==M){M=N.clientX||0;if(this.isIE){M+=this._getScrollLeft();}}return M;},getPageY:function(M){var N=M.pageY;if(!N&&0!==N){N=M.clientY||0;if(this.isIE){N+=this._getScrollTop();}}return N;},getXY:function(M){return[this.getPageX(M),this.getPageY(M)];},getRelatedTarget:function(N){var M=N.relatedTarget;if(!M){if(N.type=="mouseout"){M=N.toElement;}else{if(N.type=="mouseover"){M=N.fromElement;}}}return this.resolveTextNode(M);},getTime:function(O){if(!O.time){var N=new Date().getTime();try{O.time=N;}catch(M){this.lastError=M;return N;}}return O.time;},stopEvent:function(M){this.stopPropagation(M);this.preventDefault(M);},stopPropagation:function(M){if(M.stopPropagation){M.stopPropagation();}else{M.cancelBubble=true;}},preventDefault:function(M){if(M.preventDefault){M.preventDefault();}else{M.returnValue=false;}},getEvent:function(O,M){var N=O||window.event;if(!N){var P=this.getEvent.caller;while(P){N=P.arguments[0];if(N&&Event==N.constructor){break;}P=P.caller;}}return N;},getCharCode:function(N){var M=N.keyCode||N.charCode||0;if(YAHOO.env.ua.webkit&&(M in D)){M=D[M];}return M;},_getCacheIndex:function(Q,R,P){for(var O=0,N=I.length;O<N;O=O+1){var M=I[O];if(M&&M[this.FN]==P&&M[this.EL]==Q&&M[this.TYPE]==R){return O;}}return -1;},generateId:function(M){var N=M.id;if(!N){N="yuievtautoid-"+A;++A;M.id=N;}return N;},_isValidCollection:function(N){try{return(N&&typeof N!=="string"&&N.length&&!N.tagName&&!N.alert&&typeof N[0]!=="undefined");}catch(M){return false;}},elCache:{},getEl:function(M){return(typeof M==="string")?document.getElementById(M):M;},clearCache:function(){},DOMReadyEvent:new YAHOO.util.CustomEvent("DOMReady",this),_load:function(N){if(!H){H=true;var M=YAHOO.util.Event;M._ready();M._tryPreloadAttach();}},_ready:function(N){var M=YAHOO.util.Event;if(!M.DOMReady){M.DOMReady=true;M.DOMReadyEvent.fire();M._simpleRemove(document,"DOMContentLoaded",M._ready);}},_tryPreloadAttach:function(){if(F.length===0){C=0;if(this._interval){clearInterval(this._interval);this._interval=null;}return;}if(this.locked){return;}if(this.isIE){if(!this.DOMReady){this.startInterval();return;}}this.locked=true;var S=!H;if(!S){S=(C>0&&F.length>0);}var R=[];var T=function(V,W){var U=V;if(W.overrideContext){if(W.overrideContext===true){U=W.obj;}else{U=W.overrideContext;}}W.fn.call(U,W.obj);};var N,M,Q,P,O=[];for(N=0,M=F.length;N<M;N=N+1){Q=F[N];if(Q){P=this.getEl(Q.id);if(P){if(Q.checkReady){if(H||P.nextSibling||!S){O.push(Q);F[N]=null;}}else{T(P,Q);F[N]=null;}}else{R.push(Q);}}}for(N=0,M=O.length;N<M;N=N+1){Q=O[N];T(this.getEl(Q.id),Q);}C--;if(S){for(N=F.length-1;N>-1;N--){Q=F[N];if(!Q||!Q.id){F.splice(N,1);}}this.startInterval();}else{if(this._interval){clearInterval(this._interval);this._interval=null;}}this.locked=false;},purgeElement:function(Q,R,T){var O=(YAHOO.lang.isString(Q))?this.getEl(Q):Q;var S=this.getListeners(O,T),P,M;if(S){for(P=S.length-1;P>-1;P--){var N=S[P];this.removeListener(O,N.type,N.fn);}}if(R&&O&&O.childNodes){for(P=0,M=O.childNodes.length;P<M;++P){this.purgeElement(O.childNodes[P],R,T);}}},getListeners:function(O,M){var R=[],N;if(!M){N=[I,J];}else{if(M==="unload"){N=[J];}else{N=[I];}}var T=(YAHOO.lang.isString(O))?this.getEl(O):O;for(var Q=0;Q<N.length;Q=Q+1){var V=N[Q];if(V){for(var S=0,U=V.length;S<U;++S){var P=V[S];if(P&&P[this.EL]===T&&(!M||M===P[this.TYPE])){R.push({type:P[this.TYPE],fn:P[this.FN],obj:P[this.OBJ],adjust:P[this.OVERRIDE],scope:P[this.ADJ_SCOPE],index:S});}}}}return(R.length)?R:null;},_unload:function(T){var N=YAHOO.util.Event,Q,P,O,S,R,U=J.slice(),M;for(Q=0,S=J.length;Q<S;++Q){O=U[Q];if(O){M=window;if(O[N.ADJ_SCOPE]){if(O[N.ADJ_SCOPE]===true){M=O[N.UNLOAD_OBJ];}else{M=O[N.ADJ_SCOPE];}}O[N.FN].call(M,N.getEvent(T,O[N.EL]),O[N.UNLOAD_OBJ]);U[Q]=null;}}O=null;M=null;J=null;if(I){for(P=I.length-1;P>-1;P--){O=I[P];if(O){N.removeListener(O[N.EL],O[N.TYPE],O[N.FN],P);}}O=null;}G=null;N._simpleRemove(window,"unload",N._unload);},_getScrollLeft:function(){return this._getScroll()[1];},_getScrollTop:function(){return this._getScroll()[0];},_getScroll:function(){var M=document.documentElement,N=document.body;if(M&&(M.scrollTop||M.scrollLeft)){return[M.scrollTop,M.scrollLeft];}else{if(N){return[N.scrollTop,N.scrollLeft];}else{return[0,0];}}},regCE:function(){},_simpleAdd:function(){if(window.addEventListener){return function(O,P,N,M){O.addEventListener(P,N,(M));};}else{if(window.attachEvent){return function(O,P,N,M){O.attachEvent("on"+P,N);};}else{return function(){};}}}(),_simpleRemove:function(){if(window.removeEventListener){return function(O,P,N,M){O.removeEventListener(P,N,(M));};}else{if(window.detachEvent){return function(N,O,M){N.detachEvent("on"+O,M);};}else{return function(){};}}}()};}();(function(){var EU=YAHOO.util.Event;EU.on=EU.addListener;EU.onFocus=EU.addFocusListener;EU.onBlur=EU.addBlurListener;
+/* DOMReady: based on work by: Dean Edwards/John Resig/Matthias Miller */
+if(EU.isIE){YAHOO.util.Event.onDOMReady(YAHOO.util.Event._tryPreloadAttach,YAHOO.util.Event,true);var n=document.createElement("p");EU._dri=setInterval(function(){try{n.doScroll("left");clearInterval(EU._dri);EU._dri=null;EU._ready();n=null;}catch(ex){}},EU.POLL_INTERVAL);}else{if(EU.webkit&&EU.webkit<525){EU._dri=setInterval(function(){var rs=document.readyState;if("loaded"==rs||"complete"==rs){clearInterval(EU._dri);EU._dri=null;EU._ready();}},EU.POLL_INTERVAL);}else{EU._simpleAdd(document,"DOMContentLoaded",EU._ready);}}EU._simpleAdd(window,"load",EU._load);EU._simpleAdd(window,"unload",EU._unload);EU._tryPreloadAttach();})();}YAHOO.util.EventProvider=function(){};YAHOO.util.EventProvider.prototype={__yui_events:null,__yui_subscribers:null,subscribe:function(A,C,F,E){this.__yui_events=this.__yui_events||{};var D=this.__yui_events[A];if(D){D.subscribe(C,F,E);
+}else{this.__yui_subscribers=this.__yui_subscribers||{};var B=this.__yui_subscribers;if(!B[A]){B[A]=[];}B[A].push({fn:C,obj:F,overrideContext:E});}},unsubscribe:function(C,E,G){this.__yui_events=this.__yui_events||{};var A=this.__yui_events;if(C){var F=A[C];if(F){return F.unsubscribe(E,G);}}else{var B=true;for(var D in A){if(YAHOO.lang.hasOwnProperty(A,D)){B=B&&A[D].unsubscribe(E,G);}}return B;}return false;},unsubscribeAll:function(A){return this.unsubscribe(A);},createEvent:function(G,D){this.__yui_events=this.__yui_events||{};var A=D||{};var I=this.__yui_events;if(I[G]){}else{var H=A.scope||this;var E=(A.silent);var B=new YAHOO.util.CustomEvent(G,H,E,YAHOO.util.CustomEvent.FLAT);I[G]=B;if(A.onSubscribeCallback){B.subscribeEvent.subscribe(A.onSubscribeCallback);}this.__yui_subscribers=this.__yui_subscribers||{};var F=this.__yui_subscribers[G];if(F){for(var C=0;C<F.length;++C){B.subscribe(F[C].fn,F[C].obj,F[C].overrideContext);}}}return I[G];},fireEvent:function(E,D,A,C){this.__yui_events=this.__yui_events||{};var G=this.__yui_events[E];if(!G){return null;}var B=[];for(var F=1;F<arguments.length;++F){B.push(arguments[F]);}return G.fire.apply(G,B);},hasEvent:function(A){if(this.__yui_events){if(this.__yui_events[A]){return true;}}return false;}};(function(){var A=YAHOO.util.Event,C=YAHOO.lang;YAHOO.util.KeyListener=function(D,I,E,F){if(!D){}else{if(!I){}else{if(!E){}}}if(!F){F=YAHOO.util.KeyListener.KEYDOWN;}var G=new YAHOO.util.CustomEvent("keyPressed");this.enabledEvent=new YAHOO.util.CustomEvent("enabled");this.disabledEvent=new YAHOO.util.CustomEvent("disabled");if(C.isString(D)){D=document.getElementById(D);}if(C.isFunction(E)){G.subscribe(E);}else{G.subscribe(E.fn,E.scope,E.correctScope);}function H(O,N){if(!I.shift){I.shift=false;}if(!I.alt){I.alt=false;}if(!I.ctrl){I.ctrl=false;}if(O.shiftKey==I.shift&&O.altKey==I.alt&&O.ctrlKey==I.ctrl){var J,M=I.keys,L;if(YAHOO.lang.isArray(M)){for(var K=0;K<M.length;K++){J=M[K];L=A.getCharCode(O);if(J==L){G.fire(L,O);break;}}}else{L=A.getCharCode(O);if(M==L){G.fire(L,O);}}}}this.enable=function(){if(!this.enabled){A.on(D,F,H);this.enabledEvent.fire(I);}this.enabled=true;};this.disable=function(){if(this.enabled){A.removeListener(D,F,H);this.disabledEvent.fire(I);}this.enabled=false;};this.toString=function(){return"KeyListener ["+I.keys+"] "+D.tagName+(D.id?"["+D.id+"]":"");};};var B=YAHOO.util.KeyListener;B.KEYDOWN="keydown";B.KEYUP="keyup";B.KEY={ALT:18,BACK_SPACE:8,CAPS_LOCK:20,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,META:224,NUM_LOCK:144,PAGE_DOWN:34,PAGE_UP:33,PAUSE:19,PRINTSCREEN:44,RIGHT:39,SCROLL_LOCK:145,SHIFT:16,SPACE:32,TAB:9,UP:38};})();YAHOO.register("event",YAHOO.util.Event,{version:"2.7.0",build:"1796"});YAHOO.register("yahoo-dom-event", YAHOO, {version: "2.7.0", build: "1796"});
+/*
+Copyright (c) 2009, Yahoo! Inc. All rights reserved.
+Code licensed under the BSD License:
+http://developer.yahoo.net/yui/license.txt
+version: 2.7.0
+*/
+(function(){var lang=YAHOO.lang,util=YAHOO.util,Ev=util.Event;util.DataSourceBase=function(oLiveData,oConfigs){if(oLiveData===null||oLiveData===undefined){return;}this.liveData=oLiveData;this._oQueue={interval:null,conn:null,requests:[]};this.responseSchema={};if(oConfigs&&(oConfigs.constructor==Object)){for(var sConfig in oConfigs){if(sConfig){this[sConfig]=oConfigs[sConfig];}}}var maxCacheEntries=this.maxCacheEntries;if(!lang.isNumber(maxCacheEntries)||(maxCacheEntries<0)){maxCacheEntries=0;}this._aIntervals=[];this.createEvent("cacheRequestEvent");this.createEvent("cacheResponseEvent");this.createEvent("requestEvent");this.createEvent("responseEvent");this.createEvent("responseParseEvent");this.createEvent("responseCacheEvent");this.createEvent("dataErrorEvent");this.createEvent("cacheFlushEvent");var DS=util.DataSourceBase;this._sName="DataSource instance"+DS._nIndex;DS._nIndex++;};var DS=util.DataSourceBase;lang.augmentObject(DS,{TYPE_UNKNOWN:-1,TYPE_JSARRAY:0,TYPE_JSFUNCTION:1,TYPE_XHR:2,TYPE_JSON:3,TYPE_XML:4,TYPE_TEXT:5,TYPE_HTMLTABLE:6,TYPE_SCRIPTNODE:7,TYPE_LOCAL:8,ERROR_DATAINVALID:"Invalid data",ERROR_DATANULL:"Null data",_nIndex:0,_nTransactionId:0,issueCallback:function(callback,params,error,scope){if(lang.isFunction(callback)){callback.apply(scope,params);}else{if(lang.isObject(callback)){scope=callback.scope||scope||window;var callbackFunc=callback.success;if(error){callbackFunc=callback.failure;}if(callbackFunc){callbackFunc.apply(scope,params.concat([callback.argument]));}}}},parseString:function(oData){if(!lang.isValue(oData)){return null;}var string=oData+"";if(lang.isString(string)){return string;}else{return null;}},parseNumber:function(oData){if(!lang.isValue(oData)||(oData==="")){return null;}var number=oData*1;if(lang.isNumber(number)){return number;}else{return null;}},convertNumber:function(oData){return DS.parseNumber(oData);},parseDate:function(oData){var date=null;if(!(oData instanceof Date)){date=new Date(oData);}else{return oData;}if(date instanceof Date){return date;}else{return null;}},convertDate:function(oData){return DS.parseDate(oData);}});DS.Parser={string:DS.parseString,number:DS.parseNumber,date:DS.parseDate};DS.prototype={_sName:null,_aCache:null,_oQueue:null,_aIntervals:null,maxCacheEntries:0,liveData:null,dataType:DS.TYPE_UNKNOWN,responseType:DS.TYPE_UNKNOWN,responseSchema:null,toString:function(){return this._sName;},getCachedResponse:function(oRequest,oCallback,oCaller){var aCache=this._aCache;if(this.maxCacheEntries>0){if(!aCache){this._aCache=[];}else{var nCacheLength=aCache.length;if(nCacheLength>0){var oResponse=null;this.fireEvent("cacheRequestEvent",{request:oRequest,callback:oCallback,caller:oCaller});for(var i=nCacheLength-1;i>=0;i--){var oCacheElem=aCache[i];if(this.isCacheHit(oRequest,oCacheElem.request)){oResponse=oCacheElem.response;this.fireEvent("cacheResponseEvent",{request:oRequest,response:oResponse,callback:oCallback,caller:oCaller});if(i<nCacheLength-1){aCache.splice(i,1);this.addToCache(oRequest,oResponse);}oResponse.cached=true;break;}}return oResponse;}}}else{if(aCache){this._aCache=null;}}return null;},isCacheHit:function(oRequest,oCachedRequest){return(oRequest===oCachedRequest);},addToCache:function(oRequest,oResponse){var aCache=this._aCache;if(!aCache){return;}while(aCache.length>=this.maxCacheEntries){aCache.shift();}var oCacheElem={request:oRequest,response:oResponse};aCache[aCache.length]=oCacheElem;this.fireEvent("responseCacheEvent",{request:oRequest,response:oResponse});},flushCache:function(){if(this._aCache){this._aCache=[];this.fireEvent("cacheFlushEvent");}},setInterval:function(nMsec,oRequest,oCallback,oCaller){if(lang.isNumber(nMsec)&&(nMsec>=0)){var oSelf=this;var nId=setInterval(function(){oSelf.makeConnection(oRequest,oCallback,oCaller);},nMsec);this._aIntervals.push(nId);return nId;}else{}},clearInterval:function(nId){var tracker=this._aIntervals||[];for(var i=tracker.length-1;i>-1;i--){if(tracker[i]===nId){tracker.splice(i,1);clearInterval(nId);}}},clearAllIntervals:function(){var tracker=this._aIntervals||[];for(var i=tracker.length-1;i>-1;i--){clearInterval(tracker[i]);}tracker=[];},sendRequest:function(oRequest,oCallback,oCaller){var oCachedResponse=this.getCachedResponse(oRequest,oCallback,oCaller);if(oCachedResponse){DS.issueCallback(oCallback,[oRequest,oCachedResponse],false,oCaller);return null;}return this.makeConnection(oRequest,oCallback,oCaller);},makeConnection:function(oRequest,oCallback,oCaller){var tId=DS._nTransactionId++;this.fireEvent("requestEvent",{tId:tId,request:oRequest,callback:oCallback,caller:oCaller});var oRawResponse=this.liveData;this.handleResponse(oRequest,oRawResponse,oCallback,oCaller,tId);return tId;},handleResponse:function(oRequest,oRawResponse,oCallback,oCaller,tId){this.fireEvent("responseEvent",{tId:tId,request:oRequest,response:oRawResponse,callback:oCallback,caller:oCaller});var xhr=(this.dataType==DS.TYPE_XHR)?true:false;var oParsedResponse=null;var oFullResponse=oRawResponse;if(this.responseType===DS.TYPE_UNKNOWN){var ctype=(oRawResponse&&oRawResponse.getResponseHeader)?oRawResponse.getResponseHeader["Content-Type"]:null;if(ctype){if(ctype.indexOf("text/xml")>-1){this.responseType=DS.TYPE_XML;}else{if(ctype.indexOf("application/json")>-1){this.responseType=DS.TYPE_JSON;}else{if(ctype.indexOf("text/plain")>-1){this.responseType=DS.TYPE_TEXT;}}}}else{if(YAHOO.lang.isArray(oRawResponse)){this.responseType=DS.TYPE_JSARRAY;}else{if(oRawResponse&&oRawResponse.nodeType&&oRawResponse.nodeType==9){this.responseType=DS.TYPE_XML;}else{if(oRawResponse&&oRawResponse.nodeName&&(oRawResponse.nodeName.toLowerCase()=="table")){this.responseType=DS.TYPE_HTMLTABLE;}else{if(YAHOO.lang.isObject(oRawResponse)){this.responseType=DS.TYPE_JSON;}else{if(YAHOO.lang.isString(oRawResponse)){this.responseType=DS.TYPE_TEXT;}}}}}}}switch(this.responseType){case DS.TYPE_JSARRAY:if(xhr&&oRawResponse&&oRawResponse.responseText){oFullResponse=oRawResponse.responseText;}try{if(lang.isString(oFullResponse)){var parseArgs=[oFullResponse].concat(this.parseJSONArgs);
+if(lang.JSON){oFullResponse=lang.JSON.parse.apply(lang.JSON,parseArgs);}else{if(window.JSON&&JSON.parse){oFullResponse=JSON.parse.apply(JSON,parseArgs);}else{if(oFullResponse.parseJSON){oFullResponse=oFullResponse.parseJSON.apply(oFullResponse,parseArgs.slice(1));}else{while(oFullResponse.length>0&&(oFullResponse.charAt(0)!="{")&&(oFullResponse.charAt(0)!="[")){oFullResponse=oFullResponse.substring(1,oFullResponse.length);}if(oFullResponse.length>0){var arrayEnd=Math.max(oFullResponse.lastIndexOf("]"),oFullResponse.lastIndexOf("}"));oFullResponse=oFullResponse.substring(0,arrayEnd+1);oFullResponse=eval("("+oFullResponse+")");}}}}}}catch(e1){}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseArrayData(oRequest,oFullResponse);break;case DS.TYPE_JSON:if(xhr&&oRawResponse&&oRawResponse.responseText){oFullResponse=oRawResponse.responseText;}try{if(lang.isString(oFullResponse)){var parseArgs=[oFullResponse].concat(this.parseJSONArgs);if(lang.JSON){oFullResponse=lang.JSON.parse.apply(lang.JSON,parseArgs);}else{if(window.JSON&&JSON.parse){oFullResponse=JSON.parse.apply(JSON,parseArgs);}else{if(oFullResponse.parseJSON){oFullResponse=oFullResponse.parseJSON.apply(oFullResponse,parseArgs.slice(1));}else{while(oFullResponse.length>0&&(oFullResponse.charAt(0)!="{")&&(oFullResponse.charAt(0)!="[")){oFullResponse=oFullResponse.substring(1,oFullResponse.length);}if(oFullResponse.length>0){var objEnd=Math.max(oFullResponse.lastIndexOf("]"),oFullResponse.lastIndexOf("}"));oFullResponse=oFullResponse.substring(0,objEnd+1);oFullResponse=eval("("+oFullResponse+")");}}}}}}catch(e){}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseJSONData(oRequest,oFullResponse);break;case DS.TYPE_HTMLTABLE:if(xhr&&oRawResponse.responseText){var el=document.createElement("div");el.innerHTML=oRawResponse.responseText;oFullResponse=el.getElementsByTagName("table")[0];}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseHTMLTableData(oRequest,oFullResponse);break;case DS.TYPE_XML:if(xhr&&oRawResponse.responseXML){oFullResponse=oRawResponse.responseXML;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseXMLData(oRequest,oFullResponse);break;case DS.TYPE_TEXT:if(xhr&&lang.isString(oRawResponse.responseText)){oFullResponse=oRawResponse.responseText;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseTextData(oRequest,oFullResponse);break;default:oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseData(oRequest,oFullResponse);break;}oParsedResponse=oParsedResponse||{};if(!oParsedResponse.results){oParsedResponse.results=[];}if(!oParsedResponse.meta){oParsedResponse.meta={};}if(oParsedResponse&&!oParsedResponse.error){oParsedResponse=this.doBeforeCallback(oRequest,oFullResponse,oParsedResponse,oCallback);this.fireEvent("responseParseEvent",{request:oRequest,response:oParsedResponse,callback:oCallback,caller:oCaller});this.addToCache(oRequest,oParsedResponse);}else{oParsedResponse.error=true;this.fireEvent("dataErrorEvent",{request:oRequest,response:oRawResponse,callback:oCallback,caller:oCaller,message:DS.ERROR_DATANULL});}oParsedResponse.tId=tId;DS.issueCallback(oCallback,[oRequest,oParsedResponse],oParsedResponse.error,oCaller);},doBeforeParseData:function(oRequest,oFullResponse,oCallback){return oFullResponse;},doBeforeCallback:function(oRequest,oFullResponse,oParsedResponse,oCallback){return oParsedResponse;},parseData:function(oRequest,oFullResponse){if(lang.isValue(oFullResponse)){var oParsedResponse={results:oFullResponse,meta:{}};return oParsedResponse;}return null;},parseArrayData:function(oRequest,oFullResponse){if(lang.isArray(oFullResponse)){var results=[],i,j,rec,field,data;if(lang.isArray(this.responseSchema.fields)){var fields=this.responseSchema.fields;for(i=fields.length-1;i>=0;--i){if(typeof fields[i]!=="object"){fields[i]={key:fields[i]};}}var parsers={},p;for(i=fields.length-1;i>=0;--i){p=(typeof fields[i].parser==="function"?fields[i].parser:DS.Parser[fields[i].parser+""])||fields[i].converter;if(p){parsers[fields[i].key]=p;}}var arrType=lang.isArray(oFullResponse[0]);for(i=oFullResponse.length-1;i>-1;i--){var oResult={};rec=oFullResponse[i];if(typeof rec==="object"){for(j=fields.length-1;j>-1;j--){field=fields[j];data=arrType?rec[j]:rec[field.key];if(parsers[field.key]){data=parsers[field.key].call(this,data);}if(data===undefined){data=null;}oResult[field.key]=data;}}else{if(lang.isString(rec)){for(j=fields.length-1;j>-1;j--){field=fields[j];data=rec;if(parsers[field.key]){data=parsers[field.key].call(this,data);}if(data===undefined){data=null;}oResult[field.key]=data;}}}results[i]=oResult;}}else{results=oFullResponse;}var oParsedResponse={results:results};return oParsedResponse;}return null;},parseTextData:function(oRequest,oFullResponse){if(lang.isString(oFullResponse)){if(lang.isString(this.responseSchema.recordDelim)&&lang.isString(this.responseSchema.fieldDelim)){var oParsedResponse={results:[]};var recDelim=this.responseSchema.recordDelim;var fieldDelim=this.responseSchema.fieldDelim;if(oFullResponse.length>0){var newLength=oFullResponse.length-recDelim.length;if(oFullResponse.substr(newLength)==recDelim){oFullResponse=oFullResponse.substr(0,newLength);}if(oFullResponse.length>0){var recordsarray=oFullResponse.split(recDelim);for(var i=0,len=recordsarray.length,recIdx=0;i<len;++i){var bError=false,sRecord=recordsarray[i];if(lang.isString(sRecord)&&(sRecord.length>0)){var fielddataarray=recordsarray[i].split(fieldDelim);var oResult={};if(lang.isArray(this.responseSchema.fields)){var fields=this.responseSchema.fields;for(var j=fields.length-1;j>-1;j--){try{var data=fielddataarray[j];if(lang.isString(data)){if(data.charAt(0)=='"'){data=data.substr(1);}if(data.charAt(data.length-1)=='"'){data=data.substr(0,data.length-1);}var field=fields[j];
+var key=(lang.isValue(field.key))?field.key:field;if(!field.parser&&field.converter){field.parser=field.converter;}var parser=(typeof field.parser==="function")?field.parser:DS.Parser[field.parser+""];if(parser){data=parser.call(this,data);}if(data===undefined){data=null;}oResult[key]=data;}else{bError=true;}}catch(e){bError=true;}}}else{oResult=fielddataarray;}if(!bError){oParsedResponse.results[recIdx++]=oResult;}}}}}return oParsedResponse;}}return null;},parseXMLResult:function(result){var oResult={},schema=this.responseSchema;try{for(var m=schema.fields.length-1;m>=0;m--){var field=schema.fields[m];var key=(lang.isValue(field.key))?field.key:field;var data=null;var xmlAttr=result.attributes.getNamedItem(key);if(xmlAttr){data=xmlAttr.value;}else{var xmlNode=result.getElementsByTagName(key);if(xmlNode&&xmlNode.item(0)){var item=xmlNode.item(0);data=(item)?((item.text)?item.text:(item.textContent)?item.textContent:null):null;if(!data){var datapieces=[];for(var j=0,len=item.childNodes.length;j<len;j++){if(item.childNodes[j].nodeValue){datapieces[datapieces.length]=item.childNodes[j].nodeValue;}}if(datapieces.length>0){data=datapieces.join("");}}}}if(data===null){data="";}if(!field.parser&&field.converter){field.parser=field.converter;}var parser=(typeof field.parser==="function")?field.parser:DS.Parser[field.parser+""];if(parser){data=parser.call(this,data);}if(data===undefined){data=null;}oResult[key]=data;}}catch(e){}return oResult;},parseXMLData:function(oRequest,oFullResponse){var bError=false,schema=this.responseSchema,oParsedResponse={meta:{}},xmlList=null,metaNode=schema.metaNode,metaLocators=schema.metaFields||{},i,k,loc,v;try{xmlList=(schema.resultNode)?oFullResponse.getElementsByTagName(schema.resultNode):null;metaNode=metaNode?oFullResponse.getElementsByTagName(metaNode)[0]:oFullResponse;if(metaNode){for(k in metaLocators){if(lang.hasOwnProperty(metaLocators,k)){loc=metaLocators[k];v=metaNode.getElementsByTagName(loc)[0];if(v){v=v.firstChild.nodeValue;}else{v=metaNode.attributes.getNamedItem(loc);if(v){v=v.value;}}if(lang.isValue(v)){oParsedResponse.meta[k]=v;}}}}}catch(e){}if(!xmlList||!lang.isArray(schema.fields)){bError=true;}else{oParsedResponse.results=[];for(i=xmlList.length-1;i>=0;--i){var oResult=this.parseXMLResult(xmlList.item(i));oParsedResponse.results[i]=oResult;}}if(bError){oParsedResponse.error=true;}else{}return oParsedResponse;},parseJSONData:function(oRequest,oFullResponse){var oParsedResponse={results:[],meta:{}};if(lang.isObject(oFullResponse)&&this.responseSchema.resultsList){var schema=this.responseSchema,fields=schema.fields,resultsList=oFullResponse,results=[],metaFields=schema.metaFields||{},fieldParsers=[],fieldPaths=[],simpleFields=[],bError=false,i,len,j,v,key,parser,path;var buildPath=function(needle){var path=null,keys=[],i=0;if(needle){needle=needle.replace(/\[(['"])(.*?)\1\]/g,function(x,$1,$2){keys[i]=$2;return".@"+(i++);}).replace(/\[(\d+)\]/g,function(x,$1){keys[i]=parseInt($1,10)|0;return".@"+(i++);}).replace(/^\./,"");if(!/[^\w\.\$@]/.test(needle)){path=needle.split(".");for(i=path.length-1;i>=0;--i){if(path[i].charAt(0)==="@"){path[i]=keys[parseInt(path[i].substr(1),10)];}}}else{}}return path;};var walkPath=function(path,origin){var v=origin,i=0,len=path.length;for(;i<len&&v;++i){v=v[path[i]];}return v;};path=buildPath(schema.resultsList);if(path){resultsList=walkPath(path,oFullResponse);if(resultsList===undefined){bError=true;}}else{bError=true;}if(!resultsList){resultsList=[];}if(!lang.isArray(resultsList)){resultsList=[resultsList];}if(!bError){if(schema.fields){var field;for(i=0,len=fields.length;i<len;i++){field=fields[i];key=field.key||field;parser=((typeof field.parser==="function")?field.parser:DS.Parser[field.parser+""])||field.converter;path=buildPath(key);if(parser){fieldParsers[fieldParsers.length]={key:key,parser:parser};}if(path){if(path.length>1){fieldPaths[fieldPaths.length]={key:key,path:path};}else{simpleFields[simpleFields.length]={key:key,path:path[0]};}}else{}}for(i=resultsList.length-1;i>=0;--i){var r=resultsList[i],rec={};if(r){for(j=simpleFields.length-1;j>=0;--j){rec[simpleFields[j].key]=(r[simpleFields[j].path]!==undefined)?r[simpleFields[j].path]:r[j];}for(j=fieldPaths.length-1;j>=0;--j){rec[fieldPaths[j].key]=walkPath(fieldPaths[j].path,r);}for(j=fieldParsers.length-1;j>=0;--j){var p=fieldParsers[j].key;rec[p]=fieldParsers[j].parser(rec[p]);if(rec[p]===undefined){rec[p]=null;}}}results[i]=rec;}}else{results=resultsList;}for(key in metaFields){if(lang.hasOwnProperty(metaFields,key)){path=buildPath(metaFields[key...
[truncated message content] |