diff --git a/Changes b/Changes index f2ab786..a71ef71 100644 --- a/Changes +++ b/Changes @@ -1,27 +1,33 @@ Revision history for Net::FileMaker -0.062 2010-04-07 - + Minor Bugfixes - + Enhancements to the test suite +0.064 2013-03-01 + + Further documentation updates and fixes, switching to Dist::Zilla -0.06 2010-03-15 - + Localised Error strings in English, Japanese and German - + Huge amounts of boilerplate removed +0.063 2011-02-11 + + Various bugfixes and documentation modifications -0.05 2010-03-04 - + Significant changes to the entire structure of the distrobution, and as such the interface has also changed, - So please check the documentation. - + XML::Simple has been dropped for XML::Twig - + Test suite has been restructured. - + More documentation. +0.062 2010-04-07 + + Minor Bugfixes + + Enhancements to the test suite -0.04 2010-02-15 - Minor test bugfix +0.06 2010-03-15 + + Localised Error strings in English, Japanese and German + + Huge amounts of boilerplate removed -0.03 2010-02-14 - Methods renamed - see the deprecated section in the documentation, in addition basic tests are being put in. +0.05 2010-03-04 + + Significant changes to the entire structure of the distrobution, and as such the interface has also changed, + So please check the documentation. + + XML::Simple has been dropped for XML::Twig + + Test suite has been restructured. + + More documentation. -0.02 2010-01-24 - Documentation and pre-requisites fixups. +0.04 2010-02-15 + Minor test bugfix + +0.03 2010-02-14 + Methods renamed - see the deprecated section in the documentation, in addition basic tests are being put in. + +0.02 2010-01-24 + Documentation and pre-requisites fixups. 0.01 2010-01-22 This is the initial release CPANified from the existing codebase. The start of a long journey. diff --git a/MANIFEST b/MANIFEST deleted file mode 100644 index 2564691..0000000 --- a/MANIFEST +++ /dev/null @@ -1,38 +0,0 @@ -Changes -MANIFEST -Makefile.PL -README -lib/Net/FileMaker.pm -lib/Net/FileMaker/XML.pm -lib/Net/FileMaker/XML/Database.pm -lib/Net/FileMaker/XML/ResultSet.pm -lib/Net/FileMaker/XML/ResultSet/FieldsDefinition.pm -lib/Net/FileMaker/XML/ResultSet/Row.pm -lib/Net/FileMaker/XML/ResultSet/FieldsDefinition/Field.pm -lib/Net/FileMaker/Error.pm -lib/Net/FileMaker/Error/EN/XML.pm -lib/Net/FileMaker/Error/EN/XSLT.pm -lib/Net/FileMaker/Error/JA/XML.pm -lib/Net/FileMaker/Error/JA/XSLT.pm -lib/Net/FileMaker/Error/IT/XML.pm -lib/Net/FileMaker/Error/IT/XSLT.pm -lib/Net/FileMaker/Error/DE/XML.pm -t/00_load/00-net-filemaker.t -t/01_xml/00-load.t -t/01_xml/01-dbnames.t -t/01_xml/02-layoutnames.t -t/01_xml/03-scriptnames.t -t/01_xml/04-findall.t -t/01_xml/05-findany.t -t/02_error/00-load.t -t/02_error/01-en.t -t/02_error/02-ja.t -t/03_resultset/00-load.t -t/03_resultset/01-instantiation.t -t/03_resultset/02-rows.t -t/04_field_definition/00-load.t -t/04_field_definition/01-fields.t -t/05_row/00-load.t -t/05_row/01-inflated.t -t/manifest.t -t/pod.t diff --git a/Makefile.PL b/Makefile.PL deleted file mode 100644 index a8e6d2b..0000000 --- a/Makefile.PL +++ /dev/null @@ -1,34 +0,0 @@ -use strict; -use warnings; -use ExtUtils::MakeMaker; - -WriteMakefile( - NAME => 'Net::FileMaker', - AUTHOR => q{Squeeks }, - VERSION_FROM => 'lib/Net/FileMaker.pm', - ABSTRACT_FROM => 'lib/Net/FileMaker.pm', - ($ExtUtils::MakeMaker::VERSION >= 6.3002 - ? ('LICENSE'=> 'perl') - : ()), - - PREREQ_PM => { - 'Test::More' => 0, - 'LWP' => 0, - 'URI' => 0, - 'DateTime::Format::CLDR' => 0, - 'Carp' => 0, - 'XML::Twig' => "3.33", - }, - - MIN_PERL_VERSION => '5.008', - - META_MERGE => { - resources => { - repository => 'http://github.com/squeeks/Net-FileMaker' - } - }, - - test => { TESTS => join( ' ', (glob( 't/*.t'), glob('t/*/*.t'))) }, - dist => { COMPRESS => 'gzip -9f', SUFFIX => 'gz', }, - clean => { FILES => 'Net::FileMaker-*' }, -); diff --git a/README b/README deleted file mode 100644 index 080caa6..0000000 --- a/README +++ /dev/null @@ -1,61 +0,0 @@ -Net::FileMaker - -This module interacts with FileMaker Server's XML Interface. - -INSTALLATION - -To install this module, run the following commands: - - perl Makefile.PL - make - make test - make install - -SUPPORT AND DOCUMENTATION - -After installing, you can find documentation for this module with the -perldoc command. - - perldoc Net::FileMaker - -You can also look for information at: - - RT, CPAN's request tracker - http://rt.cpan.org/NoAuth/Bugs.html?Dist=Net::FileMaker - - AnnoCPAN, Annotated CPAN documentation - http://annocpan.org/dist/Net::FileMaker - - CPAN Ratings - http://cpanratings.perl.org/d/Net::FileMaker - - Search CPAN - http://search.cpan.org/dist/Net::FileMaker/ - - -THINGS TO DO - -There's plenty to worked on: - - * Better authentication handling - * Comprehensive test suite for those with an accessible FileMaker Server - * Removing redundant code - * Full support for the entire XML interface - * Better error handling - * XSLT support - * Future support to send headers to "mimmic" the PHP API - * Potentially supporting scraping the IWP interface as well - - -LICENSE AND COPYRIGHT - -Copyright (C) 2010 Squeeks. - -This program is free software; you can redistribute it and/or modify it -under the terms of either: the GNU General Public License as published -by the Free Software Foundation; or the Artistic License. - -FileMaker Server, FileMaker and other related names are trademarks of FileMaker Inc. - -See http://dev.perl.org/licenses/ for more information. - diff --git a/dist.ini b/dist.ini new file mode 100644 index 0000000..b10e3b7 --- /dev/null +++ b/dist.ini @@ -0,0 +1,22 @@ +name = Net-FileMaker +author = Squeeks +license = Perl_5 +copyright_holder = Squeeks +copyright_year = 2011 + +version = 0.064 + +[Prereqs] +perl = 5.008001 + +XML::Twig = 3.33 +LWP = 0 +URI = 0 +DateTime::Format::CLDR = 0 + +[Prereqs / TestRequires] +Test::More = 0 + +[PkgVersion] +[@Basic] + diff --git a/ignore.txt b/ignore.txt deleted file mode 100644 index e32062a..0000000 --- a/ignore.txt +++ /dev/null @@ -1,14 +0,0 @@ -blib* -Makefile -Makefile.old -Build -Build.bat -_build* -pm_to_blib* -*.tar.gz -.lwpcookies -cover_db -pod2htm*.tmp -Net::FileMaker-* -*.git* -.DS_Store diff --git a/lib/Net/FileMaker.pm b/lib/Net/FileMaker.pm index a273253..71e4003 100644 --- a/lib/Net/FileMaker.pm +++ b/lib/Net/FileMaker.pm @@ -14,52 +14,46 @@ use URI; Net::FileMaker - Interact with FileMaker services -=head1 VERSION - -Version 0.062 - -=cut - -our $VERSION = 0.062; - =head1 SYNOPSIS use Net::FileMaker; my $fms = Net::FileMaker->new(host => $host, type => 'xml'); -Net::FileMaker provides an interface to FileMaker's various HTTP-based interfaces, at present only the XML -API is supported, but further support to include XSLT and other means is planned. +Net::FileMaker provides an interface to FileMaker's various HTTP-based +interfaces, at present only the XML API is supported, but further support to +include XSLT and other means is planned. =head1 METHODS =head2 new(host => $host, type => 'xml') -Creates a new object. Host names must be valid URI. The type key specifies the type of database access - -XML, XSLT etc. At present only C is valid. If this is unspecified, XML is the default. +Creates a new object. Host names must be valid URI. The type key specifies the +type of database access - XML, XSLT etc. At present only C is valid. If +this is unspecified, XML is the default. =cut sub new { - my($class, %args) = @_; - - if($args{type} eq 'xml') - { - #TODO: Validate host is correct, must have http(s)? set first. - require Net::FileMaker::XML; - return Net::FileMaker::XML->new(%args); - } - elsif(!$args{type} || $args{type} eq '') - { - # Assume no type specified - use XML. - require Net::FileMaker::XML; - return Net::FileMaker::XML->new(%args); - } - # TODO: Add XSLT, PHP, etc. - else - { - croak 'Unknown type specified.'; - } + my($class, %args) = @_; + + if($args{type} eq 'xml') + { + #TODO: Validate host is correct, must have http(s)? set first. + require Net::FileMaker::XML; + return Net::FileMaker::XML->new(%args); + } + elsif(!$args{type} || $args{type} eq '') + { + # Assume no type specified - use XML. + require Net::FileMaker::XML; + return Net::FileMaker::XML->new(%args); + } + # TODO: Add XSLT, PHP, etc. + else + { + croak 'Unknown type specified.'; + } } @@ -73,18 +67,23 @@ Squeeks, C<< >> =head1 CONTRIBUTORS +Michele Ongaro, <> Simon Cozens, C<> Marcel Grünauer, C<> =head1 BUGS -This distrobution is in it's early stages and B. -Please keep an eye out on the change log and the documentation of new releases before submitting bug reports. +This distribution is now in maintainence mode as I (Squeeks) no longer have +access to a FileMaker Server to test functionality. If you are able to either +provide access to one or run the tests against one and provide feedback, please +get in touch so better support can be provided to this. -Please report any bugs or feature requests to C, or through -the web interface at L. I will be notified, and then you'll -automatically be notified of progress on your bug as I make changes. Please ensure to include the version of FileMaker Server -in your report. +Please report any bugs or feature requests to C, or through the web interface at +L. I will be +notified, and then you'll automatically be notified of progress on your bug as I +make changes. Please ensure to include the version of FileMaker Server in your +report. =head1 SUPPORT @@ -117,8 +116,9 @@ L =head1 DEVELOPMENT -Everyone is welcome to help towards the project with bugfixes, feature requests or contributions. -You'll find the git repository for this project is located at L. +Everyone is welcome to help towards the project with bugfixes, feature requests +or contributions. You'll find the git repository for this project is located at +L. =head1 LICENSE AND COPYRIGHT diff --git a/lib/Net/FileMaker/Error.pm b/lib/Net/FileMaker/Error.pm index b80d22c..d11f0be 100644 --- a/lib/Net/FileMaker/Error.pm +++ b/lib/Net/FileMaker/Error.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::Error; +package + Net::FileMaker::Error; use strict; use warnings; @@ -9,40 +10,45 @@ Net::FileMaker::Error - Error strings and codes =head1 SYNOPSIS -Classes within this namespace store the applicable error codes, and the localised strings for them. You don't call these modules yourself directly. To enable them, the key "error" must be defined as an ISO 639 short code when you construct your objects with L or a subclass that handles individual interface types like so: +Classes within this namespace store the applicable error codes, and the +localised strings for them. You don't call these modules yourself directly. To +enable them, the key "error" must be defined as an ISO 639 short code when you +construct your objects with L or a subclass that handles +individual interface types like so: use Net::FileMaker; my $fms = Net::FileMaker->new(host => $host, error => 'en'); =head1 LANGUAGES SUPPORTED -English, Japanese and German are presently supported with the aims of covering all languages documented by FileMaker in the future. +English, Italian, Japanese and German are presently supported with the aims of +covering all languages documented by FileMaker in the future. =cut # new( lang => $lang, type => $type) # -# Creates a new object. There is no inheritance in the Error classes, mearly factory objects. -# Both the language (in ISO 639) and type (XML/XSLT/IWP etc) needs be defined. Returns undef if -# fails to load the strings. +# Creates a new object. There is no inheritance in the Error classes, mearly +# factory objects. Both the language (in ISO 639) and type (XML/XSLT/IWP etc) +# needs be defined. Returns undef if fails to load the strings. sub new { - my($class, %args) = @_; - - if($args{lang} ne '' && $args{type} ne '') - { - #TODO: Look at Module::Load instead? - my $class = "Net/FileMaker/Error/".uc($args{lang})."/".uc($args{type}).'.pm'; - my $package = "Net::FileMaker::Error::".uc($args{lang})."::".uc($args{type}); - require $class; - #TODO: try/catch if the sub class exists? - return $package->new; - } - else - { - return; - } - + my($class, %args) = @_; + + if($args{lang} ne '' && $args{type} ne '') + { + #TODO: Look at Module::Load instead? + my $class = "Net/FileMaker/Error/".uc($args{lang})."/".uc($args{type}).'.pm'; + my $package = "Net::FileMaker::Error::".uc($args{lang})."::".uc($args{type}); + require $class; + #TODO: try/catch if the sub class exists? + return $package->new; + } + else + { + return; + } + } 1; # End of Net::FileMaker::Error diff --git a/lib/Net/FileMaker/Error/DE/XML.pm b/lib/Net/FileMaker/Error/DE/XML.pm index 96b52a0..c921113 100644 --- a/lib/Net/FileMaker/Error/DE/XML.pm +++ b/lib/Net/FileMaker/Error/DE/XML.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::Error::DE::XML; +package + Net::FileMaker::Error::DE::XML; use strict; use warnings; @@ -21,241 +22,241 @@ L my $error_codes = { - '-1' => "Unbekannter Fehler", - 0 => "Kein Fehler", - 1 => "Aktion durch Benutzer abgebrochen", - 2 => "Speicherfehler", - 3 => "Befehl nicht verfügbar (z. B. falsches Betriebssystem, falscher Modus etc.)", - 4 => "Befehl unbekannt.", - 5 => "Befehl ungültig (z. B. ist für den Scriptschritt „Feldwert setzen“ keine Formel angegeben).", - 6 => "Datei ist schreibgeschützt.", - 7 => "Speicherüberlauf", - 8 => "Leeres Ergebnis", - 9 => "Ungenügende Berechtigungen", - 10 => "Angeforderte Daten fehlen.", - 11 => "Name ist nicht gültig.", - 12 => "Name existiert bereits.", - 13 => "Datei oder Objekt ist in Gebrauch.", - 14 => "Außerhalb des gültigen Bereichs", - 15 => "Teilen durch null nicht möglich.", - 16 => "Operation fehlgeschlagen, Anfrage wiederholen (z. B. eine Benutzeranfrage).", - 17 => "Konvertierung von fremdem Zeichensatz in UTF-16 fehlgeschlagen.", - 18 => "Client muss Kontoinformationen liefern, um fortzufahren.", - 19 => "Zeichenfolge enthält andere Zeichen als A-Z, a-z, 0-9 (ASCII).", - 20 => "Befehl oder Vorgang durch ausgelöstes Script abgebrochen.", - 100 => "Datei fehlt.", - 101 => "Datensatz fehlt.", - 102 => "Feld fehlt.", - 103 => "Beziehung fehlt.", - 104 => "Script fehlt.", - 105 => "Layout fehlt.", - 106 => "Tabelle fehlt.", - 107 => "Index fehlt.", - 108 => "Werteliste nicht vorhanden.", - 109 => "Berechtigung fehlt.", - 110 => "Bezugstabellen fehlen.", - 111 => "Feldwiederholung ist ungültig.", - 112 => "Fenster fehlt.", - 113 => "Funktion fehlt.", - 114 => "Dateiverweis fehlt.", - 115 => "Menüset fehlt.", - 116 => "Layoutobjekt fehlt.", - 117 => "Datenquelle fehlt.", - 130 => "Dateien sind beschädigt oder fehlen und müssen neu installiert werden.", - 131 => "Dateien des Sprachpakets fehlen (z. B. Vorlagendateien).", - 200 => "Zugriff auf Datensatz verweigert.", - 201 => "Feld kann nicht geändert werden.", - 202 => "Zugriff auf Feld verweigert.", - 203 => "Keine zu druckenden Datensätze in der Datei bzw. Passwort erlaubt kein Drucken.", - 204 => "Kein Zugriff auf Feld(er) in Sortierfolge", - 205 => "Benutzer hat keine Zugriffsrechte, um neue Datensätze zu erstellen; Import überschreibt bestehende Daten.", - 206 => "Benutzer hat keine Zugriffsrechte, um das Passwort zu ändern, oder die Datei ist schreibgeschützt.", - 207 => "Benutzer hat nicht genügend Zugriffsrechte, um das Datenbankschema zu ändern, oder die Datei ist schreibgeschützt.", - 208 => "Passwort enthält zu wenige Zeichen.", - 209 => "Neues Passwort muss sich vom bestehenden unterscheiden.", - 210 => "Benutzerkonto ist inaktiv.", - 211 => "Passwort ist abgelaufen.", - 212 => "Ungültiges Benutzerkonto und/oder Passwort. Versuchen Sie es erneut.", - 213 => "Benutzerkonto und/oder Passwort existieren nicht.", - 214 => "Zu viele Anmeldeversuche", - 215 => "Administratorrechte können nicht dupliziert werden.", - 216 => "Gastkonto kann nicht dupliziert werden.", - 217 => "Benutzer hat nicht genügend Zugriffsrechte, um Administratorkonto zu ändern.", - 300 => "Datei ist geschützt oder in Gebrauch.", - 301 => "Datei ist blockiert durch anderen Anwender.", - 302 => "Tabelle ist blockiert durch anderen Anwender.", - 303 => "Datenbankschema ist blockiert durch anderen Anwender.", - 304 => "Layout ist blockiert durch anderen Anwender.", - 306 => "Datensatzänderungs-ID stimmt nicht überein.", - 400 => "Suchkriterien sind leer.", - 401 => "Kein Datensatz entspricht der Abfrage.", - 402 => "Kein Abgleichsfeld für eine Referenz", - 403 => "Maximales Datensatzlimit für FileMaker Pro-Demo wird überschritten.", - 404 => "Ungültige Sortierfolge", - 405 => "Angegebene Datensatzzahl übersteigt die Anzahl der ausschließbaren Datensätze.", - 406 => "Ungültige Kriterien für Ersetzen/Neunummerierung", - 407 => "Ein oder beide Gruppierfeld(er) fehlen (ungültige Beziehung).", - 408 => "Angegebenes Feld hat ein Datenformat, das diesem Befehl nicht entspricht.", - 409 => "Ungültige Importfolge", - 410 => "Ungültige Exportfolge", - 412 => "Falsche Version von FileMaker Pro verwendet, um die Datei wiederherzustellen", - 413 => "Angegebenes Feld hat ungeeigneten Feldtyp.", - 414 => "Layout kann das Ergebnis nicht anzeigen.", - 415 => "Ein oder mehrere erforderliche Bezugsdatensätze sind nicht verfügbar.", - 416 => "Primärschlüssel erforderlich für Datenquelltabelle", - 417 => "Die Datenbank ist keine unterstützte Datenquelle.", - 500 => "Datumswert entspricht nicht den Überprüfungskriterien.", - 501 => "Zeitwert entspricht nicht den Überprüfungskriterien.", - 502 => "Zahlenwert entspricht nicht den Überprüfungskriterien.", - 503 => "Feldwert entspricht nicht der Bereichsüberprüfung.", - 504 => "Feldwert entspricht nicht der Eindeutigkeitsüberprüfung.", - 505 => "Feldwert existiert nicht in der Datenbank und entspricht nicht der Existenzüberprüfung.", - 506 => "Feldwert entspricht nicht der Überprüfung nach Bestandteil einer Werteliste.", - 507 => "Feldwert entspricht nicht der Überprüfung durch Berechnung.", - 508 => "Ungültiger Wert wurde in Suchenmodus eingegeben.", - 509 => "Feld verlangt gültigen Wert.", - 510 => "Bezugswert ist leer oder nicht verfügbar.", - 511 => "Der Wert im Feld überschreitet die maximale Anzahl der zulässigen Zeichen.", - 512 => "Datensatz wurde bereits durch anderen Anwender geändert.", - 513 => "Um einen Datensatz zu erstellen, muss der Datensatz in mindestens einem Feld einen Wert haben.", - 600 => "Druckerfehler aufgetreten.", - 601 => "Kombination von Kopf- und Fußbereich übersteigt eine Seitenlänge.", - 602 => "Datenbereich passt für aktuelle Spalteneinstellung nicht auf eine Seite.", - 603 => "Verbindung zum Drucker getrennt.", - 700 => "Datei hat falschen Dateityp für Import.", - 706 => "EPSF-Datei hat keine Übersichtsgrafik.", - 707 => "Grafikfilter nicht vorhanden.", - 708 => "Dateiimport nicht möglich bzw. Farbmonitor für Import erforderlich.", - 709 => "Import des QuickTime-Films fehlgeschlagen.", - 710 => "QuickTime-Dateiverweis konnte nicht aktualisiert werden, da für Datenbankdatei nur Lesezugriff besteht.", - 711 => "Importfilter nicht vorhanden.", - 714 => "Zugriffsrechte reichen für diesen Befehl nicht aus.", - 715 => "Benannter Bereich oder Tabellenblatt von Excel konnte nicht gefunden werden.", - 716 => "Eine SQL Anfrage mit DELETE, INSERT oder UPDATE ist nicht für ODBC Import erlaubt.", - 717 => "Zum Fortsetzen des Imports bzw. Exports sind nicht genügend XML/XSL-Daten vorhanden.", - 718 => "XML-Parsingfehler (von Xerces)", - 719 => "Fehler beim Transformieren von XML mit XSL (von Xalan)", - 720 => "Fehler beim Export: Das vorgesehene Format unterstützt keine Wiederholfelder.", - 721 => "Im Parser oder Transformer ist ein unbekannter Fehler aufgetreten.", - 722 => "Daten können nicht in eine Datei importiert werden, die keine Felder hat.", - 723 => "Sie sind nicht berechtigt, Datensätze in der Zieltabelle hinzuzufügen oder zu ändern.", - 724 => "Sie sind nicht berechtigt, Datensätze in der Zieltabelle hinzuzufügen.", - 725 => "Sie sind nicht berechtigt, Datensätze in der Zieltabelle zu ändern.", - 726 => "In der Importdatei sind mehr Datensätze vorhanden als in der Zieltabelle. Nicht alle Datensätze werden importiert.", - 727 => "In der Zieltabelle sind mehr Datensätze vorhanden als in der Importdatei. Nicht alle Datensätze werden aktualisiert.", - 729 => "Fehler beim Import. Datensätze konnten nicht importiert werden.", - 730 => "Nicht unterstützte Excel-Version. Konvertieren Sie die Datei in Excel 7.0 (Excel 95), Excel 97, 2000, XP oder 2007 und versuchen Sie es erneut.", - 731 => "Die für den Import ausgewählte Datei enthält keine Daten.", - 732 => "Diese Datei kann nicht eingefügt werden, weil sie selbst weitere Dateien enthält.", - 733 => "Eine Tabelle kann nicht in sich selbst importiert werden.", - 734 => "Dieser Dateityp kann nicht als Bild dargestellt werden.", - 735 => "Dieser Dateityp kann nicht als Bild dargestellt werden. Er wird eingefügt und dann als Datei dargestellt.", - 736 => "Zu viele Daten für den Export in dieses Format. Sie werden abgeschnitten.", - 800 => "Datei konnte auf Datenträger nicht erstellt werden.", - 801 => "Temporärdatei konnte auf Systemdatenträger nicht erstellt werden.", - 802 => "Datei konnte nicht geöffnet werden. Dieser Fehler kann durch eine oder mehrere der folgenden Möglichkeiten verursacht werden: Ungültiger Datenbankname, Datei ist in FileMaker Server geschlossen, Ungültige Berechtigung", - 803 => "Datei in Einzelbenutzer-Status oder Host nicht vorhanden.", - 804 => "Datei konnte in ihrem aktuellen Status nicht mit Nur-Lese-Zugriff geöffnet werden.", - 805 => "Datei ist beschädigt; stellen Sie die Datei wieder her.", - 806 => "Datei kann mit dieser Version von FileMaker Pro nicht geöffnet werden.", - 807 => "Datei ist keine FileMaker Pro-Datei oder ist schwer beschädigt.", - 808 => "Datei kann wegen beschädigter Zugriffsrechte nicht geöffnet werden.", - 809 => "Datenträger voll", - 810 => "Datenträger fixiert", - 811 => "Temporärdatei kann nicht als FileMaker Pro-Datei geöffnet werden.", - 813 => "Fehler bei Datensatz-Synchronisation im Netzwerk", - 814 => "Datei(en) kann (können) nicht geöffnet werden, da die maximale Anzahl an Dateien geöffnet ist.", - 815 => "Referenzdatei konnte nicht geöffnet werden.", - 816 => "Datei konnte nicht konvertiert werden.", - 817 => "Der Bindungsschlüssel der Datei stimmt nicht mit dieser Laufzeitanwendung überein.", - 819 => "Lokale Kopie einer remote Datei kann nicht gespeichert werden.", - 820 => "Datei wird geschlossen.", - 821 => "Host hat die Verbindung getrennt.", - 822 => "FMI-Dateien nicht gefunden; fehlende Dateien neu installieren.", - 823 => "Datei kann nicht auf Einzelbenutzer gesetzt werden, da Gäste verbunden sind.", - 824 => "Datei ist beschädigt oder keine FileMaker-Datei.", - 900 => "Allgemeiner Fehler in der Rechtschreibprüfung", - 901 => "Standardwörterbuch nicht installiert.", - 902 => "Hilfe-System konnte nicht gestartet werden.", - 903 => "Befehl kann nicht in einer gemeinsam genutzten Datei verwendet werden.", - 904 => "Befehl kann nur in einer Datei verwendet werden, die von FileMaker Pro Server freigegeben wurde.", - 905 => "Kein aktives Feld ausgewählt, Befehl kann nur mit aktivem Feld verwendet werden.", - 906 => "Die aktuelle Datei wird nicht bereitgestellt. Der Befehl kann nur verwendet werden, wenn die Datei bereitgestellt wird.", - 920 => "Initialisierung der Rechtschreibprüfung nicht möglich.", - 921 => "Anwenderwörterbuch kann nicht zur Bearbeitung geladen werden.", - 922 => "Anwenderwörterbuch existiert nicht.", - 923 => "Anwenderwörterbuch ist schreibgeschützt.", - 951 => "Ein unerwarteter Fehler ist aufgetreten.", - 954 => "Nicht unterstützte XML-Grammatik", - 955 => "Kein Datenbankname", - 956 => "Maximale Anzahl von Datenbanksitzungen überschritten.", - 957 => "Widersprüchliche Befehle", - 958 => "Parameter fehlt in Query", - 1200 => "Generischer Rechenfehler", - 1201 => "In dieser Funktion gibt es zu wenige Parameter.", - 1202 => "In dieser Funktion gibt es zu viele Parameter.", - 1203 => "Unerwartetes Ende der Berechnung", - 1204 => "Es wird eine Zahl, eine Textkonstante, ein Feldname bzw. „(“ erwartet.", - 1205 => "Kommentar ist nicht mit „*/“ beendet.", - 1206 => "Textkonstante muss mit einem Anführungszeichen enden.", - 1207 => "Klammer unvollständig", - 1208 => "Operator fehlt, Funktion nicht gefunden oder „(“ nicht erwartet.", - 1209 => "Name (z. B. Feldname oder Layoutname) fehlt.", - 1210 => "Plugin-Funktion wurde bereits registriert.", - 1211 => "In dieser Funktion ist die Listennutzung nicht zulässig.", - 1212 => "Hier wird ein Operator (z. B. +, -, * ) erwartet.", - 1213 => "Diese Variable wurde bereits in der SetzeVars-Funktion definiert.", - 1214 => "MITTELWERT, ANZAHL, ERWEITERN, HOLEWIEDERHOLFELDWERT, MAX, MIN, NBW, STABW, SUMME und HOLEERGEBNISWERT: Ausdruck gefunden, wo nur ein Feld benötigt wird.", - 1215 => "Dieser Parameter ist ein ungültiger Statusfunktionsparameter.", - 1216 => "Als erstes Argument einer HOLEERGEBNISWERT-Funktion können nur Statistikfelder angegeben werden.", - 1217 => "Gruppierfeld ist ungültig.", - 1218 => "Zahl kann nicht berechnet werden.", - 1219 => "Ein Feld kann nicht in seiner eigenen Formel benutzt werden.", - 1220 => "Feldtyp muss normal oder berechnet sein.", - 1221 => "Datentyp muss Zahl, Datum, Zeit oder Zeitstempel sein.", - 1222 => "Formel kann nicht gespeichert werden.", - 1223 => "Die angegebene Funktion ist noch nicht implementiert.", - 1224 => "Die angegebene Funktion existiert nicht.", - 1225 => "Die angegebene Funktion wird in diesem Kontext nicht unterstützt.", - 1400 => "ODBC-Client-Treiberinitialisierung fehlgeschlagen. Stellen Sie sicher, dass die ODBC-Client- Treiber richtig installiert sind.", - 1401 => "Umgebung konnte nicht zugeteilt werden (ODBC).", - 1402 => "Umgebung konnte nicht freigegeben werden (ODBC).", - 1403 => "Verbindung trennen fehlerhaft (ODBC).", - 1404 => "Verbindung konnte nicht zugeteilt werden (ODBC).", - 1405 => "Verbindung konnte nicht freigegeben werden (ODBC).", - 1406 => "Überprüfung von SQL API fehlgeschlagen (ODBC).", - 1407 => "Anweisung konnte nicht zugeteilt werden (ODBC).", - 1408 => "Erweiterter Fehler (ODBC)", - 1409 => "Erweiterter Fehler (ODBC)", - 1410 => "Erweiterter Fehler (ODBC)", - 1411 => "Erweiterter Fehler (ODBC)", - 1412 => "Erweiterter Fehler (ODBC)", - 1413 => "Erweiterter Fehler (ODBC)", - 1450 => "Aktion erfordert PHP-Berechtigungserweiterung.", - 1451 => "Aktion erfordert, dass die aktuelle Datei remote ist.", - 1501 => "SMTP-Authentifizierung fehlgeschlagen.", - 1502 => "Verbindung vom SMTP-Server abgelehnt.", - 1503 => "SSL-Fehler", - 1504 => "Der SMTP-Server erfordert eine verschlüsselte Verbindung.", - 1505 => "Die angegebene Authentifizierung wird vom SMTP-Server nicht unterstützt.", - 1506 => "E-Mail(s) konnte(n) nicht erfolgreich versendet werden.", - 1507 => "Anmeldung am SMTP-Server nicht möglich" - + '-1' => "Unbekannter Fehler", + 0 => "Kein Fehler", + 1 => "Aktion durch Benutzer abgebrochen", + 2 => "Speicherfehler", + 3 => "Befehl nicht verfügbar (z. B. falsches Betriebssystem, falscher Modus etc.)", + 4 => "Befehl unbekannt.", + 5 => "Befehl ungültig (z. B. ist für den Scriptschritt „Feldwert setzen“ keine Formel angegeben).", + 6 => "Datei ist schreibgeschützt.", + 7 => "Speicherüberlauf", + 8 => "Leeres Ergebnis", + 9 => "Ungenügende Berechtigungen", + 10 => "Angeforderte Daten fehlen.", + 11 => "Name ist nicht gültig.", + 12 => "Name existiert bereits.", + 13 => "Datei oder Objekt ist in Gebrauch.", + 14 => "Außerhalb des gültigen Bereichs", + 15 => "Teilen durch null nicht möglich.", + 16 => "Operation fehlgeschlagen, Anfrage wiederholen (z. B. eine Benutzeranfrage).", + 17 => "Konvertierung von fremdem Zeichensatz in UTF-16 fehlgeschlagen.", + 18 => "Client muss Kontoinformationen liefern, um fortzufahren.", + 19 => "Zeichenfolge enthält andere Zeichen als A-Z, a-z, 0-9 (ASCII).", + 20 => "Befehl oder Vorgang durch ausgelöstes Script abgebrochen.", + 100 => "Datei fehlt.", + 101 => "Datensatz fehlt.", + 102 => "Feld fehlt.", + 103 => "Beziehung fehlt.", + 104 => "Script fehlt.", + 105 => "Layout fehlt.", + 106 => "Tabelle fehlt.", + 107 => "Index fehlt.", + 108 => "Werteliste nicht vorhanden.", + 109 => "Berechtigung fehlt.", + 110 => "Bezugstabellen fehlen.", + 111 => "Feldwiederholung ist ungültig.", + 112 => "Fenster fehlt.", + 113 => "Funktion fehlt.", + 114 => "Dateiverweis fehlt.", + 115 => "Menüset fehlt.", + 116 => "Layoutobjekt fehlt.", + 117 => "Datenquelle fehlt.", + 130 => "Dateien sind beschädigt oder fehlen und müssen neu installiert werden.", + 131 => "Dateien des Sprachpakets fehlen (z. B. Vorlagendateien).", + 200 => "Zugriff auf Datensatz verweigert.", + 201 => "Feld kann nicht geändert werden.", + 202 => "Zugriff auf Feld verweigert.", + 203 => "Keine zu druckenden Datensätze in der Datei bzw. Passwort erlaubt kein Drucken.", + 204 => "Kein Zugriff auf Feld(er) in Sortierfolge", + 205 => "Benutzer hat keine Zugriffsrechte, um neue Datensätze zu erstellen; Import überschreibt bestehende Daten.", + 206 => "Benutzer hat keine Zugriffsrechte, um das Passwort zu ändern, oder die Datei ist schreibgeschützt.", + 207 => "Benutzer hat nicht genügend Zugriffsrechte, um das Datenbankschema zu ändern, oder die Datei ist schreibgeschützt.", + 208 => "Passwort enthält zu wenige Zeichen.", + 209 => "Neues Passwort muss sich vom bestehenden unterscheiden.", + 210 => "Benutzerkonto ist inaktiv.", + 211 => "Passwort ist abgelaufen.", + 212 => "Ungültiges Benutzerkonto und/oder Passwort. Versuchen Sie es erneut.", + 213 => "Benutzerkonto und/oder Passwort existieren nicht.", + 214 => "Zu viele Anmeldeversuche", + 215 => "Administratorrechte können nicht dupliziert werden.", + 216 => "Gastkonto kann nicht dupliziert werden.", + 217 => "Benutzer hat nicht genügend Zugriffsrechte, um Administratorkonto zu ändern.", + 300 => "Datei ist geschützt oder in Gebrauch.", + 301 => "Datei ist blockiert durch anderen Anwender.", + 302 => "Tabelle ist blockiert durch anderen Anwender.", + 303 => "Datenbankschema ist blockiert durch anderen Anwender.", + 304 => "Layout ist blockiert durch anderen Anwender.", + 306 => "Datensatzänderungs-ID stimmt nicht überein.", + 400 => "Suchkriterien sind leer.", + 401 => "Kein Datensatz entspricht der Abfrage.", + 402 => "Kein Abgleichsfeld für eine Referenz", + 403 => "Maximales Datensatzlimit für FileMaker Pro-Demo wird überschritten.", + 404 => "Ungültige Sortierfolge", + 405 => "Angegebene Datensatzzahl übersteigt die Anzahl der ausschließbaren Datensätze.", + 406 => "Ungültige Kriterien für Ersetzen/Neunummerierung", + 407 => "Ein oder beide Gruppierfeld(er) fehlen (ungültige Beziehung).", + 408 => "Angegebenes Feld hat ein Datenformat, das diesem Befehl nicht entspricht.", + 409 => "Ungültige Importfolge", + 410 => "Ungültige Exportfolge", + 412 => "Falsche Version von FileMaker Pro verwendet, um die Datei wiederherzustellen", + 413 => "Angegebenes Feld hat ungeeigneten Feldtyp.", + 414 => "Layout kann das Ergebnis nicht anzeigen.", + 415 => "Ein oder mehrere erforderliche Bezugsdatensätze sind nicht verfügbar.", + 416 => "Primärschlüssel erforderlich für Datenquelltabelle", + 417 => "Die Datenbank ist keine unterstützte Datenquelle.", + 500 => "Datumswert entspricht nicht den Überprüfungskriterien.", + 501 => "Zeitwert entspricht nicht den Überprüfungskriterien.", + 502 => "Zahlenwert entspricht nicht den Überprüfungskriterien.", + 503 => "Feldwert entspricht nicht der Bereichsüberprüfung.", + 504 => "Feldwert entspricht nicht der Eindeutigkeitsüberprüfung.", + 505 => "Feldwert existiert nicht in der Datenbank und entspricht nicht der Existenzüberprüfung.", + 506 => "Feldwert entspricht nicht der Überprüfung nach Bestandteil einer Werteliste.", + 507 => "Feldwert entspricht nicht der Überprüfung durch Berechnung.", + 508 => "Ungültiger Wert wurde in Suchenmodus eingegeben.", + 509 => "Feld verlangt gültigen Wert.", + 510 => "Bezugswert ist leer oder nicht verfügbar.", + 511 => "Der Wert im Feld überschreitet die maximale Anzahl der zulässigen Zeichen.", + 512 => "Datensatz wurde bereits durch anderen Anwender geändert.", + 513 => "Um einen Datensatz zu erstellen, muss der Datensatz in mindestens einem Feld einen Wert haben.", + 600 => "Druckerfehler aufgetreten.", + 601 => "Kombination von Kopf- und Fußbereich übersteigt eine Seitenlänge.", + 602 => "Datenbereich passt für aktuelle Spalteneinstellung nicht auf eine Seite.", + 603 => "Verbindung zum Drucker getrennt.", + 700 => "Datei hat falschen Dateityp für Import.", + 706 => "EPSF-Datei hat keine Übersichtsgrafik.", + 707 => "Grafikfilter nicht vorhanden.", + 708 => "Dateiimport nicht möglich bzw. Farbmonitor für Import erforderlich.", + 709 => "Import des QuickTime-Films fehlgeschlagen.", + 710 => "QuickTime-Dateiverweis konnte nicht aktualisiert werden, da für Datenbankdatei nur Lesezugriff besteht.", + 711 => "Importfilter nicht vorhanden.", + 714 => "Zugriffsrechte reichen für diesen Befehl nicht aus.", + 715 => "Benannter Bereich oder Tabellenblatt von Excel konnte nicht gefunden werden.", + 716 => "Eine SQL Anfrage mit DELETE, INSERT oder UPDATE ist nicht für ODBC Import erlaubt.", + 717 => "Zum Fortsetzen des Imports bzw. Exports sind nicht genügend XML/XSL-Daten vorhanden.", + 718 => "XML-Parsingfehler (von Xerces)", + 719 => "Fehler beim Transformieren von XML mit XSL (von Xalan)", + 720 => "Fehler beim Export: Das vorgesehene Format unterstützt keine Wiederholfelder.", + 721 => "Im Parser oder Transformer ist ein unbekannter Fehler aufgetreten.", + 722 => "Daten können nicht in eine Datei importiert werden, die keine Felder hat.", + 723 => "Sie sind nicht berechtigt, Datensätze in der Zieltabelle hinzuzufügen oder zu ändern.", + 724 => "Sie sind nicht berechtigt, Datensätze in der Zieltabelle hinzuzufügen.", + 725 => "Sie sind nicht berechtigt, Datensätze in der Zieltabelle zu ändern.", + 726 => "In der Importdatei sind mehr Datensätze vorhanden als in der Zieltabelle. Nicht alle Datensätze werden importiert.", + 727 => "In der Zieltabelle sind mehr Datensätze vorhanden als in der Importdatei. Nicht alle Datensätze werden aktualisiert.", + 729 => "Fehler beim Import. Datensätze konnten nicht importiert werden.", + 730 => "Nicht unterstützte Excel-Version. Konvertieren Sie die Datei in Excel 7.0 (Excel 95), Excel 97, 2000, XP oder 2007 und versuchen Sie es erneut.", + 731 => "Die für den Import ausgewählte Datei enthält keine Daten.", + 732 => "Diese Datei kann nicht eingefügt werden, weil sie selbst weitere Dateien enthält.", + 733 => "Eine Tabelle kann nicht in sich selbst importiert werden.", + 734 => "Dieser Dateityp kann nicht als Bild dargestellt werden.", + 735 => "Dieser Dateityp kann nicht als Bild dargestellt werden. Er wird eingefügt und dann als Datei dargestellt.", + 736 => "Zu viele Daten für den Export in dieses Format. Sie werden abgeschnitten.", + 800 => "Datei konnte auf Datenträger nicht erstellt werden.", + 801 => "Temporärdatei konnte auf Systemdatenträger nicht erstellt werden.", + 802 => "Datei konnte nicht geöffnet werden. Dieser Fehler kann durch eine oder mehrere der folgenden Möglichkeiten verursacht werden: Ungültiger Datenbankname, Datei ist in FileMaker Server geschlossen, Ungültige Berechtigung", + 803 => "Datei in Einzelbenutzer-Status oder Host nicht vorhanden.", + 804 => "Datei konnte in ihrem aktuellen Status nicht mit Nur-Lese-Zugriff geöffnet werden.", + 805 => "Datei ist beschädigt; stellen Sie die Datei wieder her.", + 806 => "Datei kann mit dieser Version von FileMaker Pro nicht geöffnet werden.", + 807 => "Datei ist keine FileMaker Pro-Datei oder ist schwer beschädigt.", + 808 => "Datei kann wegen beschädigter Zugriffsrechte nicht geöffnet werden.", + 809 => "Datenträger voll", + 810 => "Datenträger fixiert", + 811 => "Temporärdatei kann nicht als FileMaker Pro-Datei geöffnet werden.", + 813 => "Fehler bei Datensatz-Synchronisation im Netzwerk", + 814 => "Datei(en) kann (können) nicht geöffnet werden, da die maximale Anzahl an Dateien geöffnet ist.", + 815 => "Referenzdatei konnte nicht geöffnet werden.", + 816 => "Datei konnte nicht konvertiert werden.", + 817 => "Der Bindungsschlüssel der Datei stimmt nicht mit dieser Laufzeitanwendung überein.", + 819 => "Lokale Kopie einer remote Datei kann nicht gespeichert werden.", + 820 => "Datei wird geschlossen.", + 821 => "Host hat die Verbindung getrennt.", + 822 => "FMI-Dateien nicht gefunden; fehlende Dateien neu installieren.", + 823 => "Datei kann nicht auf Einzelbenutzer gesetzt werden, da Gäste verbunden sind.", + 824 => "Datei ist beschädigt oder keine FileMaker-Datei.", + 900 => "Allgemeiner Fehler in der Rechtschreibprüfung", + 901 => "Standardwörterbuch nicht installiert.", + 902 => "Hilfe-System konnte nicht gestartet werden.", + 903 => "Befehl kann nicht in einer gemeinsam genutzten Datei verwendet werden.", + 904 => "Befehl kann nur in einer Datei verwendet werden, die von FileMaker Pro Server freigegeben wurde.", + 905 => "Kein aktives Feld ausgewählt, Befehl kann nur mit aktivem Feld verwendet werden.", + 906 => "Die aktuelle Datei wird nicht bereitgestellt. Der Befehl kann nur verwendet werden, wenn die Datei bereitgestellt wird.", + 920 => "Initialisierung der Rechtschreibprüfung nicht möglich.", + 921 => "Anwenderwörterbuch kann nicht zur Bearbeitung geladen werden.", + 922 => "Anwenderwörterbuch existiert nicht.", + 923 => "Anwenderwörterbuch ist schreibgeschützt.", + 951 => "Ein unerwarteter Fehler ist aufgetreten.", + 954 => "Nicht unterstützte XML-Grammatik", + 955 => "Kein Datenbankname", + 956 => "Maximale Anzahl von Datenbanksitzungen überschritten.", + 957 => "Widersprüchliche Befehle", + 958 => "Parameter fehlt in Query", + 1200 => "Generischer Rechenfehler", + 1201 => "In dieser Funktion gibt es zu wenige Parameter.", + 1202 => "In dieser Funktion gibt es zu viele Parameter.", + 1203 => "Unerwartetes Ende der Berechnung", + 1204 => "Es wird eine Zahl, eine Textkonstante, ein Feldname bzw. „(“ erwartet.", + 1205 => "Kommentar ist nicht mit „*/“ beendet.", + 1206 => "Textkonstante muss mit einem Anführungszeichen enden.", + 1207 => "Klammer unvollständig", + 1208 => "Operator fehlt, Funktion nicht gefunden oder „(“ nicht erwartet.", + 1209 => "Name (z. B. Feldname oder Layoutname) fehlt.", + 1210 => "Plugin-Funktion wurde bereits registriert.", + 1211 => "In dieser Funktion ist die Listennutzung nicht zulässig.", + 1212 => "Hier wird ein Operator (z. B. +, -, * ) erwartet.", + 1213 => "Diese Variable wurde bereits in der SetzeVars-Funktion definiert.", + 1214 => "MITTELWERT, ANZAHL, ERWEITERN, HOLEWIEDERHOLFELDWERT, MAX, MIN, NBW, STABW, SUMME und HOLEERGEBNISWERT: Ausdruck gefunden, wo nur ein Feld benötigt wird.", + 1215 => "Dieser Parameter ist ein ungültiger Statusfunktionsparameter.", + 1216 => "Als erstes Argument einer HOLEERGEBNISWERT-Funktion können nur Statistikfelder angegeben werden.", + 1217 => "Gruppierfeld ist ungültig.", + 1218 => "Zahl kann nicht berechnet werden.", + 1219 => "Ein Feld kann nicht in seiner eigenen Formel benutzt werden.", + 1220 => "Feldtyp muss normal oder berechnet sein.", + 1221 => "Datentyp muss Zahl, Datum, Zeit oder Zeitstempel sein.", + 1222 => "Formel kann nicht gespeichert werden.", + 1223 => "Die angegebene Funktion ist noch nicht implementiert.", + 1224 => "Die angegebene Funktion existiert nicht.", + 1225 => "Die angegebene Funktion wird in diesem Kontext nicht unterstützt.", + 1400 => "ODBC-Client-Treiberinitialisierung fehlgeschlagen. Stellen Sie sicher, dass die ODBC-Client- Treiber richtig installiert sind.", + 1401 => "Umgebung konnte nicht zugeteilt werden (ODBC).", + 1402 => "Umgebung konnte nicht freigegeben werden (ODBC).", + 1403 => "Verbindung trennen fehlerhaft (ODBC).", + 1404 => "Verbindung konnte nicht zugeteilt werden (ODBC).", + 1405 => "Verbindung konnte nicht freigegeben werden (ODBC).", + 1406 => "Überprüfung von SQL API fehlgeschlagen (ODBC).", + 1407 => "Anweisung konnte nicht zugeteilt werden (ODBC).", + 1408 => "Erweiterter Fehler (ODBC)", + 1409 => "Erweiterter Fehler (ODBC)", + 1410 => "Erweiterter Fehler (ODBC)", + 1411 => "Erweiterter Fehler (ODBC)", + 1412 => "Erweiterter Fehler (ODBC)", + 1413 => "Erweiterter Fehler (ODBC)", + 1450 => "Aktion erfordert PHP-Berechtigungserweiterung.", + 1451 => "Aktion erfordert, dass die aktuelle Datei remote ist.", + 1501 => "SMTP-Authentifizierung fehlgeschlagen.", + 1502 => "Verbindung vom SMTP-Server abgelehnt.", + 1503 => "SSL-Fehler", + 1504 => "Der SMTP-Server erfordert eine verschlüsselte Verbindung.", + 1505 => "Die angegebene Authentifizierung wird vom SMTP-Server nicht unterstützt.", + 1506 => "E-Mail(s) konnte(n) nicht erfolgreich versendet werden.", + 1507 => "Anmeldung am SMTP-Server nicht möglich" + }; sub new { - my $class = shift; - $class = ref($class) || $class; + my $class = shift; + $class = ref($class) || $class; - my $self = { }; - return bless $self, $class; + my $self = { }; + return bless $self, $class; } sub get_string { - my ($self, $error_code) = @_; - return $error_codes->{$error_code}; + my ($self, $error_code) = @_; + return $error_codes->{$error_code}; } 1; # End of Net::FileMaker::Error::DE::XML diff --git a/lib/Net/FileMaker/Error/EN/XML.pm b/lib/Net/FileMaker/Error/EN/XML.pm index beee781..672623a 100644 --- a/lib/Net/FileMaker/Error/EN/XML.pm +++ b/lib/Net/FileMaker/Error/EN/XML.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::Error::EN::XML; +package + Net::FileMaker::Error::EN::XML; use strict; use warnings; @@ -18,242 +19,242 @@ L =cut my $error_codes = { - - '-1' => 'Unknown error', - 0 => 'No error', - 1 => "User canceled action ", - 2 => "Memory error ", - 3 => "Command is unavailable (for example, wrong operating system, wrong mode, etc.)", - 4 => "Command is unknown", - 5 => "Command is invalid (for example, a Set Field script step does not have a calculation specified)", - 6 => "File is read-only", - 7 => "Running out of memory", - 8 => "Empty result", - 9 => "Insufficient privileges", - 10 => "Requested data is missing", - 11 => "Name is not valid", - 12 => "Name already exists", - 13 => "File or object is in use", - 14 => "Out of range", - 15 => "Can’t divide by zero", - 16 => "Operation failed, request retry (for example, a user query)", - 17 => "Attempt to convert foreign character set to UTF-16 failed", - 18 => "Client must provide account information to proceed", - 19 => "String contains characters other than A-Z, a-z, 0-9 (ASCII)", - 20 => "Command or operation cancelled by triggered script", - 100 => "File is missing", - 101 => "Record is missing", - 102 => "Field is missing", - 103 => "Relationship is missing", - 104 => "Script is missing", - 105 => "Layout is missing", - 106 => "Table is missing", - 107 => "Index is missing", - 108 => "Value list is missing", - 109 => "Privilege set is missing", - 110 => "Related tables are missing", - 111 => "Field repetition is invalid", - 112 => "Window is missing", - 113 => "Function is missing", - 114 => "File reference is missing", - 115 => "The menu set is missing", - 116 => "The layout object is missing", - 117 => "The data source is missing", - 130 => "Files are damaged or missing and must be reinstalled", - 131 => "Language pack files are missing (such as template files)", - 200 => "Record access is denied", - 201 => "Field cannot be modified", - 202 => "Field access is denied", - 203 => "No records in file to print, or password doesn’t allow print access", - 204 => "No access to field(s) in sort order", - 205 => "User does not have access privileges to create new records; import will overwrite existing data", - 206 => "User does not have password change privileges, or file is not modifiable", - 207 => "User does not have sufficient privileges to change database schema, or file is not modifiable", - 208 => "Password does not contain enough characters", - 209 => "New password must be different from existing one", - 210 => "User account is inactive", - 211 => "Password has expired", - 212 => "Invalid user account and/or password. Please try again", - 213 => "User account and/or password does not exist", - 214 => "Too many login attempts", - 215 => "Administrator privileges cannot be duplicated", - 216 => "Guest account cannot be duplicated", - 217 => "User does not have sufficient privileges to modify administrator account", - 300 => "File is locked or in use", - 301 => "Record is in use by another user", - 302 => "Table is in use by another user", - 303 => "Database schema is in use by another user", - 304 => "Layout is in use by another user", - 306 => "Record modification ID does not match", - 400 => "Find criteria are empty", - 401 => "No records match the request", - 402 => "Selected field is not a match field for a lookup", - 403 => "Exceeding maximum record limit for trial version of FileMaker Pro", - 404 => "Sort order is invalid", - 405 => "Number of records specified exceeds number of records that can be omitted", - 406 => "Replace/Reserialize criteria are invalid", - 407 => "One or both match fields are missing (invalid relationship)", - 408 => "Specified field has inappropriate data type for this operation", - 409 => "Import order is invalid", - 410 => "Export order is invalid", - 412 => "Wrong version of FileMaker Pro used to recover file", - 413 => "Specified field has inappropriate field type", - 414 => "Layout cannot display the result", - 415 => "One or more required related records are not available", - 416 => "A primary key is required from the data source table", - 417 => "The database is not a supported data source", - 500 => "Date value does not meet validation entry options", - 501 => "Time value does not meet validation entry options", - 502 => "Number value does not meet validation entry options", - 503 => "Value in field is not within the range specified in validation entry options", - 504 => "Value in field is not unique as required in validation entry options", - 505 => "Value in field is not an existing value in the database file as required in validation entry options", - 506 => "Value in field is not listed on the value list specified in validation entry option", - 507 => "Value in field failed calculation test of validation entry option", - 508 => "Invalid value entered in Find mode", - 509 => "Field requires a valid value", - 510 => "Related value is empty or unavailable", - 511 => "Value in field exceeds maximum number of allowed characters", - 512 => "The record was already modified by another user", - 513 => "To create a record, the record has to have a value in at least one field", - 600 => "Print error has occurred", - 601 => "Combined header and footer exceed one page", - 602 => "Body doesn’t fit on a page for current column setup", - 603 => "Print connection lost", - 700 => "File is of the wrong file type for import", - 706 => "EPSF file has no preview image", - 707 => "Graphic translator cannot be found", - 708 => "Can’t import the file or need color monitor support to import file", - 709 => "QuickTime movie import failed", - 710 => "Unable to update QuickTime file reference because the database file is read-only", - 711 => "Import translator cannot be found", - 714 => "Password privileges do not allow the operation", - 715 => "Specified Excel worksheet or named range is missing", - 716 => "A SQL query using DELETE, INSERT, or UPDATE is not allowed for ODBC import", - 717 => "There is not enough XML/XSL information to proceed with the import or export", - 718 => "Error in parsing XML file (from Xerces)", - 719 => "Error in transforming XML using XSL (from Xalan)", - 720 => "Error when exporting; intended format does not support repeating fields", - 721 => "Unknown error occurred in the parser or the transformer", - 722 => "Cannot import data into a file that has no fields", - 723 => "You do not have permission to add records to or modify records in the target table", - 724 => "You do not have permission to add records to the target table", - 725 => "You do not have permission to modify records in the target table", - 726 => "There are more records in the import file than in the target table. Not all records were imported", - 727 => "There are more records in the target table than in the import file. Not all records were updated", - 729 => "Errors occurred during import. Records could not be imported", - 730 => "Unsupported Excel version. Convert file to Excel 7.0 (Excel 95), 97, 2000, XP, or 2007 format and try again.", - 731 => "The file you are importing from contains no data", - 732 => "This file cannot be inserted because it contains other files", - 733 => "A table cannot be imported into itself", - 734 => "This file type cannot be displayed as a picture", - 735 => "This file type cannot be displayed as a picture. It will be inserted and displayed as a file", - 736 => "There is too much data to be exported to this format. It will be truncated", - 800 => "Unable to create file on disk", - 801 => "Unable to create temporary file on System disk", - 802 => "Unable to open file. This error can be caused by one or more of the following: invalid database name, the file is closed in FileMaker Server or invalid permission", - 803 => "File is single user or host cannot be found", - 804 => "File cannot be opened as read-only in its current state", - 805 => "File is damaged; use Recover command", - 806 => "File cannot be opened with this version of FileMaker Pro", - 807 => "File is not a FileMaker Pro file or is severely damaged", - 808 => "Cannot open file because access privileges are damaged", - 809 => "Disk/volume is full", - 810 => "Disk/volume is locked", - 811 => "Temporary file cannot be opened as FileMaker Pro file", - 813 => "Record Synchronization error on network", - 814 => "File(s) cannot be opened because maximum number is open", - 815 => "Couldn’t open lookup file", - 816 => "Unable to convert file", - 817 => "Unable to open file because it does not belong to this solution", - 819 => "Cannot save a local copy of a remote file", - 820 => "File is in the process of being closed", - 821 => "Host forced a disconnect", - 822 => "FMI files not found; reinstall missing files", - 823 => "Cannot set file to single-user, guests are connected", - 824 => "File is damaged or not a FileMaker file", - 900 => "General spelling engine error", - 901 => "Main spelling dictionary not installed", - 902 => "Could not launch the Help system", - 903 => "Command cannot be used in a shared file", - 904 => "Command can only be used in a file hosted under FileMaker Server", - 905 => "No active field selected; command can only be used if there is an active field", - 906 => "The current file is not shared; command can be used only if the file is shared", - 920 => "Can’t initialize the spelling engine", - 921 => "User dictionary cannot be loaded for editing", - 922 => "User dictionary cannot be found", - 923 => "User dictionary is read-only", - 951 => "An unexpected error occurred", - 954 => "Unsupported XML grammar", - 955 => "No database name", - 956 => "Maximum number of database sessions exceeded", - 957 => "Conflicting commands", - 958 => "Parameter missing in query", - 1200 => "Generic calculation error", - 1201 => "Too few parameters in the function", - 1202 => "Too many parameters in the function", - 1203 => "Unexpected end of calculation", - 1204 => "Number, text constant, field name or '(' expected", - 1205 => "Comment is not terminated with '*/'", - 1206 => "Text constant must end with a quotation mark", - 1207 => "Unbalanced parenthesis", - 1208 => "Operator missing, function not found or '(' not expected", - 1209 => "Name (such as field name or layout name) is missing", - 1210 => "Plug-in function has already been registered", - 1211 => "List usage is not allowed in this function", - 1212 => "An operator (for example, +, -, *) is expected here", - 1213 => "This variable has already been defined in the Let function", - 1214 => "AVERAGE, COUNT, EXTEND, GETREPETITION, MAX, MIN, NPV, STDEV, SUM and GETSUMMARY: expression found where a field alone is needed", - 1215 => "This parameter is an invalid Get function parameter", - 1216 => "Only Summary fields allowed as first argument in GETSUMMARY", - 1217 => "Break field is invalid", - 1218 => "Cannot evaluate the number", - 1219 => "A field cannot be used in its own formula", - 1220 => "Field type must be normal or calculated", - 1221 => "Data type must be number, date, time, or timestamp", - 1222 => "Calculation cannot be stored", - 1223 => "The function referred to is not yet implemented", - 1224 => "The function referred to does not exist", - 1225 => "The function referred to is not supported in this context", - 1400 => "ODBC client driver initialization failed; make sure the ODBC client drivers are properly installed.", - 1401 => "Failed to allocate environment (ODBC)", - 1402 => "Failed to free environment (ODBC)", - 1403 => "Failed to disconnect (ODBC)", - 1404 => "Failed to allocate connection (ODBC)", - 1405 => "Failed to free connection (ODBC)", - 1406 => "Failed check for SQL API (ODBC)", - 1407 => "Failed to allocate statement (ODBC)", - 1408 => "Extended error (ODBC)", - 1409 => "Extended error (ODBC)", - 1410 => "Extended error (ODBC)", - 1411 => "Extended error (ODBC)", - 1412 => "Extended error (ODBC)", - 1413 => "Extended error (ODBC)", - 1450 => "Action requires PHP privilege extension", - 1451 => "Action requires that current file be remote", - 1501 => "SMTP authentication failed", - 1502 => "Connection refused by SMTP server", - 1503 => "Error with SSL", - 1504 => "SMTP server requires the connection to be encrypted", - 1505 => "Specified authentication is not supported by SMTP server", - 1506 => "Email message(s) could not be sent successfully", - 1507 => "Unable to log in to the SMTP server" - + + '-1' => 'Unknown error', + 0 => 'No error', + 1 => "User canceled action ", + 2 => "Memory error ", + 3 => "Command is unavailable (for example, wrong operating system, wrong mode, etc.)", + 4 => "Command is unknown", + 5 => "Command is invalid (for example, a Set Field script step does not have a calculation specified)", + 6 => "File is read-only", + 7 => "Running out of memory", + 8 => "Empty result", + 9 => "Insufficient privileges", + 10 => "Requested data is missing", + 11 => "Name is not valid", + 12 => "Name already exists", + 13 => "File or object is in use", + 14 => "Out of range", + 15 => "Can’t divide by zero", + 16 => "Operation failed, request retry (for example, a user query)", + 17 => "Attempt to convert foreign character set to UTF-16 failed", + 18 => "Client must provide account information to proceed", + 19 => "String contains characters other than A-Z, a-z, 0-9 (ASCII)", + 20 => "Command or operation cancelled by triggered script", + 100 => "File is missing", + 101 => "Record is missing", + 102 => "Field is missing", + 103 => "Relationship is missing", + 104 => "Script is missing", + 105 => "Layout is missing", + 106 => "Table is missing", + 107 => "Index is missing", + 108 => "Value list is missing", + 109 => "Privilege set is missing", + 110 => "Related tables are missing", + 111 => "Field repetition is invalid", + 112 => "Window is missing", + 113 => "Function is missing", + 114 => "File reference is missing", + 115 => "The menu set is missing", + 116 => "The layout object is missing", + 117 => "The data source is missing", + 130 => "Files are damaged or missing and must be reinstalled", + 131 => "Language pack files are missing (such as template files)", + 200 => "Record access is denied", + 201 => "Field cannot be modified", + 202 => "Field access is denied", + 203 => "No records in file to print, or password doesn’t allow print access", + 204 => "No access to field(s) in sort order", + 205 => "User does not have access privileges to create new records; import will overwrite existing data", + 206 => "User does not have password change privileges, or file is not modifiable", + 207 => "User does not have sufficient privileges to change database schema, or file is not modifiable", + 208 => "Password does not contain enough characters", + 209 => "New password must be different from existing one", + 210 => "User account is inactive", + 211 => "Password has expired", + 212 => "Invalid user account and/or password. Please try again", + 213 => "User account and/or password does not exist", + 214 => "Too many login attempts", + 215 => "Administrator privileges cannot be duplicated", + 216 => "Guest account cannot be duplicated", + 217 => "User does not have sufficient privileges to modify administrator account", + 300 => "File is locked or in use", + 301 => "Record is in use by another user", + 302 => "Table is in use by another user", + 303 => "Database schema is in use by another user", + 304 => "Layout is in use by another user", + 306 => "Record modification ID does not match", + 400 => "Find criteria are empty", + 401 => "No records match the request", + 402 => "Selected field is not a match field for a lookup", + 403 => "Exceeding maximum record limit for trial version of FileMaker Pro", + 404 => "Sort order is invalid", + 405 => "Number of records specified exceeds number of records that can be omitted", + 406 => "Replace/Reserialize criteria are invalid", + 407 => "One or both match fields are missing (invalid relationship)", + 408 => "Specified field has inappropriate data type for this operation", + 409 => "Import order is invalid", + 410 => "Export order is invalid", + 412 => "Wrong version of FileMaker Pro used to recover file", + 413 => "Specified field has inappropriate field type", + 414 => "Layout cannot display the result", + 415 => "One or more required related records are not available", + 416 => "A primary key is required from the data source table", + 417 => "The database is not a supported data source", + 500 => "Date value does not meet validation entry options", + 501 => "Time value does not meet validation entry options", + 502 => "Number value does not meet validation entry options", + 503 => "Value in field is not within the range specified in validation entry options", + 504 => "Value in field is not unique as required in validation entry options", + 505 => "Value in field is not an existing value in the database file as required in validation entry options", + 506 => "Value in field is not listed on the value list specified in validation entry option", + 507 => "Value in field failed calculation test of validation entry option", + 508 => "Invalid value entered in Find mode", + 509 => "Field requires a valid value", + 510 => "Related value is empty or unavailable", + 511 => "Value in field exceeds maximum number of allowed characters", + 512 => "The record was already modified by another user", + 513 => "To create a record, the record has to have a value in at least one field", + 600 => "Print error has occurred", + 601 => "Combined header and footer exceed one page", + 602 => "Body doesn’t fit on a page for current column setup", + 603 => "Print connection lost", + 700 => "File is of the wrong file type for import", + 706 => "EPSF file has no preview image", + 707 => "Graphic translator cannot be found", + 708 => "Can’t import the file or need color monitor support to import file", + 709 => "QuickTime movie import failed", + 710 => "Unable to update QuickTime file reference because the database file is read-only", + 711 => "Import translator cannot be found", + 714 => "Password privileges do not allow the operation", + 715 => "Specified Excel worksheet or named range is missing", + 716 => "A SQL query using DELETE, INSERT, or UPDATE is not allowed for ODBC import", + 717 => "There is not enough XML/XSL information to proceed with the import or export", + 718 => "Error in parsing XML file (from Xerces)", + 719 => "Error in transforming XML using XSL (from Xalan)", + 720 => "Error when exporting; intended format does not support repeating fields", + 721 => "Unknown error occurred in the parser or the transformer", + 722 => "Cannot import data into a file that has no fields", + 723 => "You do not have permission to add records to or modify records in the target table", + 724 => "You do not have permission to add records to the target table", + 725 => "You do not have permission to modify records in the target table", + 726 => "There are more records in the import file than in the target table. Not all records were imported", + 727 => "There are more records in the target table than in the import file. Not all records were updated", + 729 => "Errors occurred during import. Records could not be imported", + 730 => "Unsupported Excel version. Convert file to Excel 7.0 (Excel 95), 97, 2000, XP, or 2007 format and try again.", + 731 => "The file you are importing from contains no data", + 732 => "This file cannot be inserted because it contains other files", + 733 => "A table cannot be imported into itself", + 734 => "This file type cannot be displayed as a picture", + 735 => "This file type cannot be displayed as a picture. It will be inserted and displayed as a file", + 736 => "There is too much data to be exported to this format. It will be truncated", + 800 => "Unable to create file on disk", + 801 => "Unable to create temporary file on System disk", + 802 => "Unable to open file. This error can be caused by one or more of the following: invalid database name, the file is closed in FileMaker Server or invalid permission", + 803 => "File is single user or host cannot be found", + 804 => "File cannot be opened as read-only in its current state", + 805 => "File is damaged; use Recover command", + 806 => "File cannot be opened with this version of FileMaker Pro", + 807 => "File is not a FileMaker Pro file or is severely damaged", + 808 => "Cannot open file because access privileges are damaged", + 809 => "Disk/volume is full", + 810 => "Disk/volume is locked", + 811 => "Temporary file cannot be opened as FileMaker Pro file", + 813 => "Record Synchronization error on network", + 814 => "File(s) cannot be opened because maximum number is open", + 815 => "Couldn’t open lookup file", + 816 => "Unable to convert file", + 817 => "Unable to open file because it does not belong to this solution", + 819 => "Cannot save a local copy of a remote file", + 820 => "File is in the process of being closed", + 821 => "Host forced a disconnect", + 822 => "FMI files not found; reinstall missing files", + 823 => "Cannot set file to single-user, guests are connected", + 824 => "File is damaged or not a FileMaker file", + 900 => "General spelling engine error", + 901 => "Main spelling dictionary not installed", + 902 => "Could not launch the Help system", + 903 => "Command cannot be used in a shared file", + 904 => "Command can only be used in a file hosted under FileMaker Server", + 905 => "No active field selected; command can only be used if there is an active field", + 906 => "The current file is not shared; command can be used only if the file is shared", + 920 => "Can’t initialize the spelling engine", + 921 => "User dictionary cannot be loaded for editing", + 922 => "User dictionary cannot be found", + 923 => "User dictionary is read-only", + 951 => "An unexpected error occurred", + 954 => "Unsupported XML grammar", + 955 => "No database name", + 956 => "Maximum number of database sessions exceeded", + 957 => "Conflicting commands", + 958 => "Parameter missing in query", + 1200 => "Generic calculation error", + 1201 => "Too few parameters in the function", + 1202 => "Too many parameters in the function", + 1203 => "Unexpected end of calculation", + 1204 => "Number, text constant, field name or '(' expected", + 1205 => "Comment is not terminated with '*/'", + 1206 => "Text constant must end with a quotation mark", + 1207 => "Unbalanced parenthesis", + 1208 => "Operator missing, function not found or '(' not expected", + 1209 => "Name (such as field name or layout name) is missing", + 1210 => "Plug-in function has already been registered", + 1211 => "List usage is not allowed in this function", + 1212 => "An operator (for example, +, -, *) is expected here", + 1213 => "This variable has already been defined in the Let function", + 1214 => "AVERAGE, COUNT, EXTEND, GETREPETITION, MAX, MIN, NPV, STDEV, SUM and GETSUMMARY: expression found where a field alone is needed", + 1215 => "This parameter is an invalid Get function parameter", + 1216 => "Only Summary fields allowed as first argument in GETSUMMARY", + 1217 => "Break field is invalid", + 1218 => "Cannot evaluate the number", + 1219 => "A field cannot be used in its own formula", + 1220 => "Field type must be normal or calculated", + 1221 => "Data type must be number, date, time, or timestamp", + 1222 => "Calculation cannot be stored", + 1223 => "The function referred to is not yet implemented", + 1224 => "The function referred to does not exist", + 1225 => "The function referred to is not supported in this context", + 1400 => "ODBC client driver initialization failed; make sure the ODBC client drivers are properly installed.", + 1401 => "Failed to allocate environment (ODBC)", + 1402 => "Failed to free environment (ODBC)", + 1403 => "Failed to disconnect (ODBC)", + 1404 => "Failed to allocate connection (ODBC)", + 1405 => "Failed to free connection (ODBC)", + 1406 => "Failed check for SQL API (ODBC)", + 1407 => "Failed to allocate statement (ODBC)", + 1408 => "Extended error (ODBC)", + 1409 => "Extended error (ODBC)", + 1410 => "Extended error (ODBC)", + 1411 => "Extended error (ODBC)", + 1412 => "Extended error (ODBC)", + 1413 => "Extended error (ODBC)", + 1450 => "Action requires PHP privilege extension", + 1451 => "Action requires that current file be remote", + 1501 => "SMTP authentication failed", + 1502 => "Connection refused by SMTP server", + 1503 => "Error with SSL", + 1504 => "SMTP server requires the connection to be encrypted", + 1505 => "Specified authentication is not supported by SMTP server", + 1506 => "Email message(s) could not be sent successfully", + 1507 => "Unable to log in to the SMTP server" + }; sub new { - my $class = shift; - $class = ref($class) || $class; + my $class = shift; + $class = ref($class) || $class; - my $self = { }; - return bless $self, $class; + my $self = { }; + return bless $self, $class; } sub get_string { - my ($self, $error_code) = @_; - return $error_codes->{$error_code}; + my ($self, $error_code) = @_; + return $error_codes->{$error_code}; } 1; # End of Net::FileMaker::Error::EN::XML diff --git a/lib/Net/FileMaker/Error/EN/XSLT.pm b/lib/Net/FileMaker/Error/EN/XSLT.pm index dfbb5cf..87a8ebf 100644 --- a/lib/Net/FileMaker/Error/EN/XSLT.pm +++ b/lib/Net/FileMaker/Error/EN/XSLT.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::Error::EN::XSLT; +package + Net::FileMaker::Error::EN::XSLT; use strict; use warnings; @@ -19,57 +20,57 @@ L my $error_codes = { - '-1' => "Unknown error", - 0 => "No error", - 10000 => "Invalid header name", - 10001 => "Invalid HTTP status code", - 10100 => "Unknown session error", - 10101 => "Requested session name is already used", - 10102 => "Session could not be accessed - maybe it does not exist", - 10103 => "Session has timed out", - 10104 => "Specified session object does not exist", - 10200 => "Unknown messaging error", - 10201 => "Message formatting error", - 10202 => "Message SMTP fields error", - 10203 => "Message “To Field” error", - 10204 => "Message “From Field” error", - 10205 => "Message “CC Field” error", - 10206 => "Message “BCC Field” error", - 10207 => "Message “Subject Field” error", - 10208 => "Message “Reply-To Field” error", - 10209 => "Message body error", - 10210 => "Recursive mail error - attempted to call send_email() inside an email XSLT stylesheet", - 10211 => "SMTP authentication error - either login failed or wrong type of authentication provided", - 10212 => "Invalid function usage - attempted to call set_header(), set_status_code() or set_cookie() inside an email XSLT stylesheet", - 10213 => "SMTP server is invalid or is not working.", - 10300 => "Unknown formatting error", - 10301 => "Invalid date time format", - 10302 => "Invalid date format", - 10303 => "Invalid time format", - 10304 => "Invalid day format", - 10305 => "Improperly formatted date time string", - 10306 => "Improperly formatted date string", - 10307 => "Improperly formatted time string", - 10308 => "Improperly formatted day string", - 10309 => "Unsupported text encoding", - 10310 => "Invalid URL encoding", - 10311 => "Regular expression pattern error" - + '-1' => "Unknown error", + 0 => "No error", + 10000 => "Invalid header name", + 10001 => "Invalid HTTP status code", + 10100 => "Unknown session error", + 10101 => "Requested session name is already used", + 10102 => "Session could not be accessed - maybe it does not exist", + 10103 => "Session has timed out", + 10104 => "Specified session object does not exist", + 10200 => "Unknown messaging error", + 10201 => "Message formatting error", + 10202 => "Message SMTP fields error", + 10203 => "Message “To Field” error", + 10204 => "Message “From Field” error", + 10205 => "Message “CC Field” error", + 10206 => "Message “BCC Field” error", + 10207 => "Message “Subject Field” error", + 10208 => "Message “Reply-To Field” error", + 10209 => "Message body error", + 10210 => "Recursive mail error - attempted to call send_email() inside an email XSLT stylesheet", + 10211 => "SMTP authentication error - either login failed or wrong type of authentication provided", + 10212 => "Invalid function usage - attempted to call set_header(), set_status_code() or set_cookie() inside an email XSLT stylesheet", + 10213 => "SMTP server is invalid or is not working.", + 10300 => "Unknown formatting error", + 10301 => "Invalid date time format", + 10302 => "Invalid date format", + 10303 => "Invalid time format", + 10304 => "Invalid day format", + 10305 => "Improperly formatted date time string", + 10306 => "Improperly formatted date string", + 10307 => "Improperly formatted time string", + 10308 => "Improperly formatted day string", + 10309 => "Unsupported text encoding", + 10310 => "Invalid URL encoding", + 10311 => "Regular expression pattern error" + }; sub new { - my $class = shift; - $class = ref($class) || $class; + my $class = shift; + $class = ref($class) || $class; - my $self = { }; - return bless $self, $class; + my $self = { }; + return bless $self, $class; } sub get_string { - my ($self, $error_code) = @_; - return $error_codes->{$error_code}; + my ($self, $error_code) = @_; + return $error_codes->{$error_code}; } 1; # End of Net::FileMaker::Error::EN::XSLT diff --git a/lib/Net/FileMaker/Error/IT/XML.pm b/lib/Net/FileMaker/Error/IT/XML.pm index 2355676..ac02aaa 100644 --- a/lib/Net/FileMaker/Error/IT/XML.pm +++ b/lib/Net/FileMaker/Error/IT/XML.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::Error::IT::XML; +package + Net::FileMaker::Error::IT::XML; use strict; use warnings; @@ -18,7 +19,7 @@ L =cut my $error_codes = { - '-1' => 'Errore sconosciuto', + '-1' => 'Errore sconosciuto', 0 => 'Nessun errore', 1 => "Azione annullata dall'utente", 2 => "Errore di memoria", @@ -27,167 +28,167 @@ my $error_codes = { 5 => "Comando non valido (ad esempio, un'istruzione di script Definisci il campo priva di calcolo)", 6 => "File di sola lettura", 7 => "Memoria esaurita", - 8 => "Risultato vuoto", - 9 => "Privilegi insufficienti", - 10 => "Dati richiesti non disponibili", - 11 => "Nome non valido", - 12 => "Il nome esiste già", - 13 => "File o oggetto in uso", - 14 => "Fuori intervallo", - 15 => "Impossibile dividere per zero", - 16 => "Operazione non riuscita, nuovo tentativo richiesta (ad esempio una query dell'utente)", - 17 => "Tentativo di convertire il set di caratteri stranieri in UTF-16 non riuscito", - 18 => "Il client deve fornire le informazioni sull'account per procedere", - 19 => "La stringa contiene caratteri diversi da A-Z, a-z, 0-9 (ASCII)", - 20 => "Comando o operazione cancellata dallo script triggerato", - 100 => "Manca un file", - 101 => "Manca un record", - 102 => "Manca un campo", - 103 => "Manca una relazione", - 104 => "Manca uno script", - 105 => "Manca un formato", - 106 => "Manca una tabella", - 107 => "Manca un indice", - 108 => "Manca una lista valori", - 109 => "Manca un set di privilegi", - 110 => "Mancano tabelle correlate", - 111 => "Ripetizione campo non valida", - 112 => "Manca una finestra", - 113 => "Manca una funzione", - 114 => "Manca un riferimento al file", - 115 => "Il set di menu specificato non è presente", - 116 => "L'oggetto formato specificato non è presente", - 117 => "L'origine dati specificata non è presente", - 130 => "File danneggiati o non presenti; reinstallarli", - 131 => "Impossibile trovare i file del supporto per la lingua (come i file modello)", - 200 => "Accesso al record negato", - 201 => "Impossibile modificare il campo", - 202 => "Accesso al campo negato", - 203 => "Nel file non c'è nessun record da stampare o la password non consente l'accesso alla stampa", - 204 => "Nessun accesso ai campi nei criteri di ordinamento", - 205 => "L'utente non dispone dei privilegi di accesso per creare nuovi record; l'importazione sovrascriverà i dati esistenti", - 206 => "L'utente non dispone del privilegio per cambiare la password o il file non è modificabile", - 207 => "L'utente non ha privilegi sufficienti per cambiare lo schema del database, oppure il file non è modificabile", - 208 => "La password non contiene abbastanza caratteri", - 209 => "La nuova password deve essere diversa da quella esistente", - 210 => "L'account utente è inattivo", - 211 => "La password è scaduta", - 212 => "Nome utente e/o password non validi. Riprovare", - 213 => "Il nome utente e/o la password non esistono", - 214 => "Troppi tentativi di accesso", - 215 => "I privilegi di amministratore non possono essere duplicati", - 216 => "L'account Ospite non può essere duplicato", - 217 => "L'utente non dispone di privilegi sufficienti per modificare l'account Admin", - 300 => "File bloccato o in uso", - 301 => "Record usato da un altro utente", - 302 => "Tabella usata da un altro utente", - 303 => "Schema database usato da un altro utente", - 304 => "Formato usato da un altro utente", - 306 => "ID modifica del record non corrispondente", - 400 => "Criteri di ricerca vuoti", - 401 => "Nessun record soddisfa la richiesta", - 402 => "Il campo selezionato non è un campo di confronto per un riferimento", - 403 => "Limite massimo di record per la versione di prova di FileMaker Pro superato", - 404 => "Criterio di ordinamento non valido", - 405 => "Il numero di record specificato supera il numero di record che possono essere omessi", - 406 => "Criteri di sostituzione/riserializzazione non validi", - 407 => "Manca uno o entrambi i campi di confronto (relazione non valida)", - 408 => "Tipo di dati associato al campo specificato non valido per questa operazione", - 409 => "Ordine di importazione non valido", - 410 => "Ordine di esportazione non valido", - 412 => "Per recuperare il file è stata usata una versione errata di FileMaker Pro", - 413 => "Tipo di campo non valido", - 414 => "Il formato non può visualizzare il risultato", - 415 => "Uno o più record correlati richiesti non sono disponibili", - 416 => "Chiave primaria richiesta dalla tabella di origine dati", - 417 => "Il database non è supportato per le operazioni ODBC", - 500 => "Il valore della data non soddisfa le opzioni di verifica", - 501 => "Il valore dell'ora non soddisfa le opzioni di verifica", - 502 => "Il valore del numero non soddisfa le opzioni di verifica", - 503 => "Il valore nel campo non è compreso nell'intervallo specificato nelle opzioni di verifica", - 504 => "Il valore del campo non è univoco come richiesto dalle opzioni di verifica", - 505 => "Il valore del campo non esiste nel file di database come richiesto dalle opzioni di verifica", - 506 => "Il valore nel campo non è elencato nella lista di valori specificata nelle opzioni di verifica", - 507 => "Il valore nel campo non ha superato il test del calcolo dell'opzione di verifica", - 508 => "Valore non valido immesso in modo Trova", - 509 => "Il campo richiede un valore valido", - 510 => "Valore correlato vuoto o non disponibile", - 511 => "Il valore immesso nel campo supera il numero massimo di caratteri consentiti", - 512 => "Il record è già stato modificato da un altro utente", - 513 => "Il record deve comprendere almeno un valore in un campo per poter essere creato", - 600 => "Errore di stampa", - 601 => "La combinazione di intestazione e piè di pagina supera una pagina", - 602 => "Il corpo non rientra in una pagina per l'impostazione della colonna corrente", - 603 => "Connessione di stampa interrotta", - 700 => "Tipo di file errato per l'importazione", - 706 => "File EPSF privo di immagine di anteprima", - 707 => "Impossibile trovare traduttore per immagini", - 708 => "Impossibile importare il file. È necessario un computer a colori", - 709 => "Non è riuscita l'importazione del filmato QuickTime", - 710 => "Impossibile aggiornare il riferimento QuickTime. Il file di database è di sola lettura", - 711 => "Impossibile trovare il traduttore per l'importazione", - 714 => "Operazione non consentita dai privilegi della password", - 715 => "È stato specificato un foglio di lavoro di Excel o un intervallo con nome mancante", - 716 => "Una query SQL che impiega istruzioni DELETE, INSERT o UPDATE non è consentita per l'importazione ODBC", - 717 => "Informazioni XML/XSL insufficienti per procedere con l'importazione o l'esportazione", - 718 => "Errore di analisi del file XML (da Xerces)", - 719 => "Errore di conversione XML usando XSL (da Xalan)", - 720 => "Errore durante l'esportazione; il formato desiderato non supporta i campi multipli", - 721 => "Errore sconosciuto nel parser o nel convertitore", - 722 => "Impossibile importare dati in un file che non ha campi", - 723 => "Non si dispone dell'autorizzazione per aggiungere o modificare record nella tabella di destinazione", - 724 => "Non si dispone dell'autorizzazione per aggiungere record alla tabella di destinazione", - 725 => "Non si dispone dell'autorizzazione per modificare record nella tabella di destinazione", - 726 => "Vi sono più record nel file di importazione che nella tabella di destinazione. Non tutti i record sono stati importati", - 727 => "Vi sono più record nella tabella di destinazione che nel file di importazione. Non tutti i record sono stati aggiornati", - 729 => "Errori durante l'importazione. Impossibile importare i record", - 730 => "Versione Excel non supportata. (Convertire il file in formato Excel 7.0 (Excel 95), Excel 97, 2000 o XP e riprovare)", - 731 => "Il file da importare non contiene dati", - 732 => "Questo file non può essere inserito perché contiene altri file", - 733 => "Una tabella non può essere importata in se stessa", - 734 => "I file di questo tipo non possono essere visualizzati come immagine", - 735 => "I file di questo tipo non possono essere visualizzati come immagine. Verranno inseriti e visualizzati come file", - 736 => "Troppi dati da esportare in questo formato. Sarà troncato", - 800 => "Impossibile creare il file su disco", - 801 => "Impossibile creare il file temporaneo sul disco di sistema", - 802 => "Impossibile aprire il file", - 803 => "Il file è per un singolo utente oppure non è stato possibile trovare l'host", - 804 => "Impossibile aprire il file.", - 805 => "Usare il comando Recupera", - 806 => "Impossibile aprire il file con questa versione di FileMaker Pro", - 807 => "Il file non è un file FileMaker Pro oppure è gravemente danneggiato", - 808 => "Impossibile aprire il file. I privilegi di accesso sono danneggiati", - 809 => "Il disco o il volume è pieno", - 810 => "Il disco o il volume è protetto", - 811 => "Impossibile aprire il file temporaneo come file di FileMaker Pro", - 813 => "Errore di sincronizzazione del record in rete", - 814 => "Impossibile aprire i file. È già aperto il numero massimo", - 815 => "Impossibile aprire il file di riferimento", - 816 => "Impossibile convertire il file", - 817 => "Impossibile aprire il file poiché non fa parte di questa soluzione", - 819 => "Impossibile salvare una copia locale di un file remoto", - 820 => "File in fase di chiusura", - 821 => "L'host ha forzato una disconnessione", - 822 => "File FMI non trovati; reinstallare i file non presenti", - 823 => "Impossibile impostare il file su utente singolo; alcuni ospiti sono connessi", - 824 => "Il file è danneggiato o non è un file FileMaker", - 900 => "Errore generico del modulo di gestione del controllo ortografico", - 901 => "Dizionario principale non installato", - 902 => "Impossibile avviare la Guida", - 903 => "Impossibile usare il comando in un file condiviso", - 904 => "Questo comando non può essere usato in un file ospitato sotto FileMaker Server", - 905 => "Non è selezionato nessun campo attivo; il comando può essere usato solo se un campo è attivo", - 906 => "Il file corrente deve essere condiviso per usare questo comando", - 920 => "Impossibile inizializzare il modulo di gestione del controllo ortografico", - 921 => "Impossibile caricare il dizionario utente per la modifica", - 922 => "Impossibile trovare il dizionario utente", - 923 => "Il dizionario utente è di sola lettura", - 951 => "Errore imprevisto (*)", - 954 => "Grammatica XML non supportata (*)", - 955 => "Nessun nome per il database (*)", - 956 => "È stato superato il numero massimo di sessioni del database (*)", - 957 => "Conflitto tra i comandi (*)", - 958 => "Parametro mancante (*)", + 8 => "Risultato vuoto", + 9 => "Privilegi insufficienti", + 10 => "Dati richiesti non disponibili", + 11 => "Nome non valido", + 12 => "Il nome esiste già", + 13 => "File o oggetto in uso", + 14 => "Fuori intervallo", + 15 => "Impossibile dividere per zero", + 16 => "Operazione non riuscita, nuovo tentativo richiesta (ad esempio una query dell'utente)", + 17 => "Tentativo di convertire il set di caratteri stranieri in UTF-16 non riuscito", + 18 => "Il client deve fornire le informazioni sull'account per procedere", + 19 => "La stringa contiene caratteri diversi da A-Z, a-z, 0-9 (ASCII)", + 20 => "Comando o operazione cancellata dallo script triggerato", + 100 => "Manca un file", + 101 => "Manca un record", + 102 => "Manca un campo", + 103 => "Manca una relazione", + 104 => "Manca uno script", + 105 => "Manca un formato", + 106 => "Manca una tabella", + 107 => "Manca un indice", + 108 => "Manca una lista valori", + 109 => "Manca un set di privilegi", + 110 => "Mancano tabelle correlate", + 111 => "Ripetizione campo non valida", + 112 => "Manca una finestra", + 113 => "Manca una funzione", + 114 => "Manca un riferimento al file", + 115 => "Il set di menu specificato non è presente", + 116 => "L'oggetto formato specificato non è presente", + 117 => "L'origine dati specificata non è presente", + 130 => "File danneggiati o non presenti; reinstallarli", + 131 => "Impossibile trovare i file del supporto per la lingua (come i file modello)", + 200 => "Accesso al record negato", + 201 => "Impossibile modificare il campo", + 202 => "Accesso al campo negato", + 203 => "Nel file non c'è nessun record da stampare o la password non consente l'accesso alla stampa", + 204 => "Nessun accesso ai campi nei criteri di ordinamento", + 205 => "L'utente non dispone dei privilegi di accesso per creare nuovi record; l'importazione sovrascriverà i dati esistenti", + 206 => "L'utente non dispone del privilegio per cambiare la password o il file non è modificabile", + 207 => "L'utente non ha privilegi sufficienti per cambiare lo schema del database, oppure il file non è modificabile", + 208 => "La password non contiene abbastanza caratteri", + 209 => "La nuova password deve essere diversa da quella esistente", + 210 => "L'account utente è inattivo", + 211 => "La password è scaduta", + 212 => "Nome utente e/o password non validi. Riprovare", + 213 => "Il nome utente e/o la password non esistono", + 214 => "Troppi tentativi di accesso", + 215 => "I privilegi di amministratore non possono essere duplicati", + 216 => "L'account Ospite non può essere duplicato", + 217 => "L'utente non dispone di privilegi sufficienti per modificare l'account Admin", + 300 => "File bloccato o in uso", + 301 => "Record usato da un altro utente", + 302 => "Tabella usata da un altro utente", + 303 => "Schema database usato da un altro utente", + 304 => "Formato usato da un altro utente", + 306 => "ID modifica del record non corrispondente", + 400 => "Criteri di ricerca vuoti", + 401 => "Nessun record soddisfa la richiesta", + 402 => "Il campo selezionato non è un campo di confronto per un riferimento", + 403 => "Limite massimo di record per la versione di prova di FileMaker Pro superato", + 404 => "Criterio di ordinamento non valido", + 405 => "Il numero di record specificato supera il numero di record che possono essere omessi", + 406 => "Criteri di sostituzione/riserializzazione non validi", + 407 => "Manca uno o entrambi i campi di confronto (relazione non valida)", + 408 => "Tipo di dati associato al campo specificato non valido per questa operazione", + 409 => "Ordine di importazione non valido", + 410 => "Ordine di esportazione non valido", + 412 => "Per recuperare il file è stata usata una versione errata di FileMaker Pro", + 413 => "Tipo di campo non valido", + 414 => "Il formato non può visualizzare il risultato", + 415 => "Uno o più record correlati richiesti non sono disponibili", + 416 => "Chiave primaria richiesta dalla tabella di origine dati", + 417 => "Il database non è supportato per le operazioni ODBC", + 500 => "Il valore della data non soddisfa le opzioni di verifica", + 501 => "Il valore dell'ora non soddisfa le opzioni di verifica", + 502 => "Il valore del numero non soddisfa le opzioni di verifica", + 503 => "Il valore nel campo non è compreso nell'intervallo specificato nelle opzioni di verifica", + 504 => "Il valore del campo non è univoco come richiesto dalle opzioni di verifica", + 505 => "Il valore del campo non esiste nel file di database come richiesto dalle opzioni di verifica", + 506 => "Il valore nel campo non è elencato nella lista di valori specificata nelle opzioni di verifica", + 507 => "Il valore nel campo non ha superato il test del calcolo dell'opzione di verifica", + 508 => "Valore non valido immesso in modo Trova", + 509 => "Il campo richiede un valore valido", + 510 => "Valore correlato vuoto o non disponibile", + 511 => "Il valore immesso nel campo supera il numero massimo di caratteri consentiti", + 512 => "Il record è già stato modificato da un altro utente", + 513 => "Il record deve comprendere almeno un valore in un campo per poter essere creato", + 600 => "Errore di stampa", + 601 => "La combinazione di intestazione e piè di pagina supera una pagina", + 602 => "Il corpo non rientra in una pagina per l'impostazione della colonna corrente", + 603 => "Connessione di stampa interrotta", + 700 => "Tipo di file errato per l'importazione", + 706 => "File EPSF privo di immagine di anteprima", + 707 => "Impossibile trovare traduttore per immagini", + 708 => "Impossibile importare il file. È necessario un computer a colori", + 709 => "Non è riuscita l'importazione del filmato QuickTime", + 710 => "Impossibile aggiornare il riferimento QuickTime. Il file di database è di sola lettura", + 711 => "Impossibile trovare il traduttore per l'importazione", + 714 => "Operazione non consentita dai privilegi della password", + 715 => "È stato specificato un foglio di lavoro di Excel o un intervallo con nome mancante", + 716 => "Una query SQL che impiega istruzioni DELETE, INSERT o UPDATE non è consentita per l'importazione ODBC", + 717 => "Informazioni XML/XSL insufficienti per procedere con l'importazione o l'esportazione", + 718 => "Errore di analisi del file XML (da Xerces)", + 719 => "Errore di conversione XML usando XSL (da Xalan)", + 720 => "Errore durante l'esportazione; il formato desiderato non supporta i campi multipli", + 721 => "Errore sconosciuto nel parser o nel convertitore", + 722 => "Impossibile importare dati in un file che non ha campi", + 723 => "Non si dispone dell'autorizzazione per aggiungere o modificare record nella tabella di destinazione", + 724 => "Non si dispone dell'autorizzazione per aggiungere record alla tabella di destinazione", + 725 => "Non si dispone dell'autorizzazione per modificare record nella tabella di destinazione", + 726 => "Vi sono più record nel file di importazione che nella tabella di destinazione. Non tutti i record sono stati importati", + 727 => "Vi sono più record nella tabella di destinazione che nel file di importazione. Non tutti i record sono stati aggiornati", + 729 => "Errori durante l'importazione. Impossibile importare i record", + 730 => "Versione Excel non supportata. (Convertire il file in formato Excel 7.0 (Excel 95), Excel 97, 2000 o XP e riprovare)", + 731 => "Il file da importare non contiene dati", + 732 => "Questo file non può essere inserito perché contiene altri file", + 733 => "Una tabella non può essere importata in se stessa", + 734 => "I file di questo tipo non possono essere visualizzati come immagine", + 735 => "I file di questo tipo non possono essere visualizzati come immagine. Verranno inseriti e visualizzati come file", + 736 => "Troppi dati da esportare in questo formato. Sarà troncato", + 800 => "Impossibile creare il file su disco", + 801 => "Impossibile creare il file temporaneo sul disco di sistema", + 802 => "Impossibile aprire il file", + 803 => "Il file è per un singolo utente oppure non è stato possibile trovare l'host", + 804 => "Impossibile aprire il file.", + 805 => "Usare il comando Recupera", + 806 => "Impossibile aprire il file con questa versione di FileMaker Pro", + 807 => "Il file non è un file FileMaker Pro oppure è gravemente danneggiato", + 808 => "Impossibile aprire il file. I privilegi di accesso sono danneggiati", + 809 => "Il disco o il volume è pieno", + 810 => "Il disco o il volume è protetto", + 811 => "Impossibile aprire il file temporaneo come file di FileMaker Pro", + 813 => "Errore di sincronizzazione del record in rete", + 814 => "Impossibile aprire i file. È già aperto il numero massimo", + 815 => "Impossibile aprire il file di riferimento", + 816 => "Impossibile convertire il file", + 817 => "Impossibile aprire il file poiché non fa parte di questa soluzione", + 819 => "Impossibile salvare una copia locale di un file remoto", + 820 => "File in fase di chiusura", + 821 => "L'host ha forzato una disconnessione", + 822 => "File FMI non trovati; reinstallare i file non presenti", + 823 => "Impossibile impostare il file su utente singolo; alcuni ospiti sono connessi", + 824 => "Il file è danneggiato o non è un file FileMaker", + 900 => "Errore generico del modulo di gestione del controllo ortografico", + 901 => "Dizionario principale non installato", + 902 => "Impossibile avviare la Guida", + 903 => "Impossibile usare il comando in un file condiviso", + 904 => "Questo comando non può essere usato in un file ospitato sotto FileMaker Server", + 905 => "Non è selezionato nessun campo attivo; il comando può essere usato solo se un campo è attivo", + 906 => "Il file corrente deve essere condiviso per usare questo comando", + 920 => "Impossibile inizializzare il modulo di gestione del controllo ortografico", + 921 => "Impossibile caricare il dizionario utente per la modifica", + 922 => "Impossibile trovare il dizionario utente", + 923 => "Il dizionario utente è di sola lettura", + 951 => "Errore imprevisto (*)", + 954 => "Grammatica XML non supportata (*)", + 955 => "Nessun nome per il database (*)", + 956 => "È stato superato il numero massimo di sessioni del database (*)", + 957 => "Conflitto tra i comandi (*)", + 958 => "Parametro mancante (*)", 1200 => "Errore di calcolo generico", 1201 => "Troppi pochi parametri nella funzione", 1202 => "Troppi parametri nella funzione", diff --git a/lib/Net/FileMaker/Error/IT/XSLT.pm b/lib/Net/FileMaker/Error/IT/XSLT.pm index 7020f84..d89b8b2 100644 --- a/lib/Net/FileMaker/Error/IT/XSLT.pm +++ b/lib/Net/FileMaker/Error/IT/XSLT.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::Error::IT::XSLT; +package + Net::FileMaker::Error::IT::XSLT; use strict; use warnings; @@ -19,41 +20,41 @@ L my $error_codes = { - '-1' => "Errore sconosciuto", - 0 => "Nessun errore", - 10000 => "Nome instestazione non valido", - 10001 => "Il codice status HTTP non è valido", - 10100 => "Errore di sessione sconosciuto", - 10101 => "Il nome della sessione è già in uso", - 10102 => "Non posso accedere alla sessione - probabilmente non esiste", - 10103 => "Sessione scaduta", - 10104 => "L'oggetto della sessione non esiste", - 10200 => "Messaggio di errore sconosciuto", - 10201 => "Errore di formattazione sconosciuto", - 10202 => "Errore nei campi SMTP ", - 10203 => "Errore “Al Campo”", - 10204 => "Errore “Dal Campo”", - 10205 => "Errore “Campo CC ”", - 10206 => "Errore “Campo BCC”", - 10207 => "Errore “Campo Oggetto”", - 10208 => "Errore “Campo Inoltra”", - 10209 => "Errore nel corpo della email", - 10210 => "Errore ricorsivo - tentativo di chiamata a send_email() dentro un foglio di stile XSLT di una email", - 10211 => "Errore di autenticazione SMTP - login fallito o errato metodo di autenticazione", - 10212 => "Utilizzo non valido di una funzione - tentativo di chiamata a set_header(), set_status_code() o set_cookie() dentro un foglio di stile XSLT di una email", - 10213 => "Il server SMTP non è valido o non sta funzionando.", - 10300 => "Errore di formattazione sconosciuto", - 10301 => "Formato data-tempo non valido", - 10302 => "Formato data non valido", - 10303 => "Formato tempo non valido", - 10304 => "Formato giorno non valido", - 10305 => "Formattazione errata per la stringa data-tempo", - 10306 => "Formattazione errata per la stringa data", - 10307 => "Formattazione errata per la stringa tempo", - 10308 => "Formattazione errata per la stringa giorno", - 10309 => "Codifica testo non supportata", - 10310 => "Codifica URL non supportata", - 10311 => "Errore nel pattern dell'Espressione Regolare" + '-1' => "Errore sconosciuto", + 0 => "Nessun errore", + 10000 => "Nome instestazione non valido", + 10001 => "Il codice status HTTP non è valido", + 10100 => "Errore di sessione sconosciuto", + 10101 => "Il nome della sessione è già in uso", + 10102 => "Non posso accedere alla sessione - probabilmente non esiste", + 10103 => "Sessione scaduta", + 10104 => "L'oggetto della sessione non esiste", + 10200 => "Messaggio di errore sconosciuto", + 10201 => "Errore di formattazione sconosciuto", + 10202 => "Errore nei campi SMTP ", + 10203 => "Errore “Al Campo”", + 10204 => "Errore “Dal Campo”", + 10205 => "Errore “Campo CC ”", + 10206 => "Errore “Campo BCC”", + 10207 => "Errore “Campo Oggetto”", + 10208 => "Errore “Campo Inoltra”", + 10209 => "Errore nel corpo della email", + 10210 => "Errore ricorsivo - tentativo di chiamata a send_email() dentro un foglio di stile XSLT di una email", + 10211 => "Errore di autenticazione SMTP - login fallito o errato metodo di autenticazione", + 10212 => "Utilizzo non valido di una funzione - tentativo di chiamata a set_header(), set_status_code() o set_cookie() dentro un foglio di stile XSLT di una email", + 10213 => "Il server SMTP non è valido o non sta funzionando.", + 10300 => "Errore di formattazione sconosciuto", + 10301 => "Formato data-tempo non valido", + 10302 => "Formato data non valido", + 10303 => "Formato tempo non valido", + 10304 => "Formato giorno non valido", + 10305 => "Formattazione errata per la stringa data-tempo", + 10306 => "Formattazione errata per la stringa data", + 10307 => "Formattazione errata per la stringa tempo", + 10308 => "Formattazione errata per la stringa giorno", + 10309 => "Codifica testo non supportata", + 10310 => "Codifica URL non supportata", + 10311 => "Errore nel pattern dell'Espressione Regolare" }; diff --git a/lib/Net/FileMaker/Error/JA/XML.pm b/lib/Net/FileMaker/Error/JA/XML.pm index db10cc1..4ce0662 100644 --- a/lib/Net/FileMaker/Error/JA/XML.pm +++ b/lib/Net/FileMaker/Error/JA/XML.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::Error::JA::XML; +package + Net::FileMaker::Error::JA::XML; use strict; use warnings; @@ -21,241 +22,241 @@ L my $error_codes = { - '-1' => "原因不明のエラー", - 0 => "エラーなし", - 1 => "ユーザによるキャンセル", - 2 => "メモリエラー", - 3 => "コマンドが使用できません(たとえば誤ったオペレーティングシステム、誤ったモードなど)", - 4 => "コマンドが見つかりません", - 5 => "コマンドが無効です(たとえば、[フィールド設定] スクリプトステップに計算式が指定されていな い場合など)", - 6 => "ファイルが読み取り専用です", - 7 => "メモリ不足", - 8 => "空白の結果", - 9 => "アクセス権が不十分です", - 10 => "要求されたデータが見つかりません", - 11 => "名前が有効ではありません", - 12 => "名前がすでに存在します", - 13 => "ファイルまたはオブジェクトが使用中です", - 14 => "範囲外", - 15 => "0で割ることができません", - 16 => "処理に失敗したため、再試行が必要です(たとえば、ユーザクエリーなど)", - 17 => "外国語の文字セットの UTF-16 への変換に失敗しました", - 18 => "続行するには、クライアントはアカウント情報を指定する必要があります", - 19 => "文字列に A から Z、a から z、0 から 9(ASCII)以外の文字が含まれています", - 20 => "コマンドまたは操作がスクリプトトリガによってキャンセルされました", - 100 => "ファイルが見つかりません", - 101 => "レコードが見つかりません", - 102 => "フィールドが見つかりません", - 103 => "リレーションシップが見つかりません", - 104 => "スクリプトが見つかりません", - 105 => "レイアウトが見つかりません", - 106 => "テーブルが見つかりません", - 107 => "索引が見つかりません", - 108 => "値一覧が見つかりません", - 109 => "アクセス権セットが見つかりません", - 110 => "関連テーブルが見つかりません", - 111 => "フィールドの繰り返しが無効です", - 112 => "ウインドウが見つかりません", - 113 => "関数が見つかりません", - 114 => "ファイル参照が見つかりません", - 115 => "メニューセットが見つかりません", - 116 => "レイアウトオブジェクトが見つかりません", - 117 => "データソースが見つかりません", - 130 => "ファイルが損傷しているか見つからないため、再インストールする必要があります", - 131 => "言語パックファイルが見つかりません(テンプレートなど)", - 200 => "レコードアクセスが拒否されました", - 201 => "フィールドを変更できません", - 202 => "フィールドアクセスが拒否されました", - 203 => "ファイルに印刷するレコードがないか、入力したパスワードでは印刷できません", - 204 => "ソート優先順位に指定されたフィールドにアクセスできません", - 205 => "ユーザに新規レコードを作成するアクセス権がありません。既存のデータはインポートしたデータ で上書きされます", - 206 => "ユーザにパスワードの変更アクセス権がないか、変更可能なファイルではありません", - 207 => "ユーザにデータベーススキーマを変更する十分なアクセス権がないか、変更可能なファイルではあ りません", - 208 => "パスワードに十分な文字が含まれていません", - 209 => "既存のパスワードと新規パスワードを同一にすることはできません", - 210 => "ユーザアカウントが非アクティブです", - 211 => "パスワードが期限切れです", - 212 => "ユーザアカウントまたはパスワードが無効です。再試行してください", - 213 => "ユーザアカウントまたはパスワードが存在しません", - 214 => "ログイン試行回数が多すぎます", - 215 => "管理者権限は複製できません", - 216 => "ゲストアカウントは複製できません", - 217 => "ユーザに管理者アカウントを変更する十分なアクセス権がありません", - 300 => "ファイルがロックされているか、使用中です", - 301 => "別のユーザがレコードを使用中です", - 302 => "別のユーザがテーブルを使用中です", - 303 => "別のユーザがデータベーススキーマを使用中です", - 304 => "別のユーザがレイアウトを使用中です", - 306 => "レコード修正 ID が一致しません", - 400 => "検索条件が空です", - 401 => "検索条件に一致するレコードがありません", - 402 => "選択したフィールドはルックアップの照合フィールドではありません", - 403 => "評価版の FileMaker Pro に設定されている最大レコード数の制限を超過しています", - 404 => "ソート優先順位が無効です", - 405 => "指定したレコード数が除外可能なレコード数を超過しています", - 406 => "全置換またはシリアル番号の再入力に指定された条件が無効です", - 407 => "片方または両方の照合フィールドが欠けています(無効なリレーションシップ)", - 408 => "指定されたフィールドのデータが不適切なため、この処理を実行できません", - 409 => "インポート順が無効です", - 410 => "エスクポート順が無効です", - 412 => "ファイルの修復に、誤ったバージョンの FileMaker Pro が使用されました", - 413 => "指定されたフィールドのフィールドタイプが不適切です", - 414 => "レイアウトに結果を表示できません", - 415 => "1つまたは複数の必要な関連レコードが使用できません", - 416 => "データソーステーブルからプライマリキーが必要です", - 417 => "データベースが、サポートされているデータソースではありません", - 500 => "日付の値が入力値の制限を満たしていません", - 501 => "時刻の値が入力値の制限を満たしていません", - 502 => "数字の値が入力値の制限を満たしていません", - 503 => "フィールドの値が入力値の制限オプションに指定されている範囲内に入っていません", - 504 => "フィールドの値が入力値の制限オプションで要求されているようにユニークな値になっていません", - 505 => "フィールドの値が入力値の制限オプションで要求されているようにデータベースファイル内の既存 値になっていません", - 506 => "フィールドの値が入力値の制限オプションに指定されている値一覧に含まれていません", - 507 => "フィールドの値が入力値の制限オプションに指定されている計算式を満たしません", - 508 => "検索モードに無効な値が入力されました", - 509 => "フィールドに有効な値が必要です", - 510 => "関連する値が空であるか、使用できません", - 511 => "フィールド内の値が最大文字数を超過しました", - 512 => "レコードがすでに別のユーザによって変更されています", - 513 => "レコードを作成するには、レコードの少なくとも1つのフィールドに値がある必要があります", - 600 => "印刷エラーが発生しました", - 601 => "ヘッダとフッタの高さを加算するとページの高さを超えます", - 602 => "現在の段数設定ではボディ部分がページ内に収まりません", - 603 => "印刷接続が遮断されました", - 700 => "インポートできないファイルタイプです", - 706 => "EPSF ファイルにプレビューイメージがありません", - 707 => "グラフィックの変換ファイルが見つかりません", - 708 => "ファイルをインポートできないか、ファイルをインポートするにはカラーのコンピュータが必要で す", - 709 => "QuickTime ムービーのインポートに失敗しました", - 710 => "データベースファイルが読み取り専用になっているため QuickTime ファイルの参照を更新できませ ん", - 711 => "インポートの変換ファイルが見つかりません", - 714 => "入力したパスワードでは設定されている権限が不足しているためこの操作は認められていません", - 715 => "指定された Excel ワークシートまたは名前の付いた範囲がありません", - 716 => "ODBC インポートでは、DELETE、INSERT、または UPDATE を使用する SQL クエリーは使用でき ません", - 717 => "インポートまたはエクスポートを続行するための十分な XML/XSLT 情報がありません", - 718 => "(Xerces からの)XML ファイルの解析エラーです", - 719 => "(Xalan からの)XSL を使用した XML 変換エラーです", - 720 => "エクスポート時のエラー。対象のドキュメントフォーマットでは繰り返しフィールドはサポートさ れていません", - 721 => "パーサまたはトランスフォーマで原因不明のエラーが発生しました", - 722 => "フィールドのないファイルにデータをインポートすることはできません", - 723 => "インポート先のテーブルでレコードを追加または変更する権限がありません", - 724 => "インポート先のテーブルにレコードを追加する権限がありません", - 725 => "インポート先のテーブルでレコードを変更する権限がありません", - 726 => "インポートファイルのレコードの方がインポート先のテーブルのレコードよりも多くなっていま す。一部のレコードはインポートされません", - 727 => "インポート先のテーブルのレコードの方がインポートファイルのレコードよりも多くなっていま す。一部のレコードは更新されません", - 729 => "インポート中にエラーが発生しました。レコードをインポートすることができません", - 730 => "サポートされていない Excel のバージョンです。ファイルを Excel 7.0(Excel 95)、Excel 97、2000、 XPまたは2007 のフォーマットに変換して、もう一度実行してください", - 731 => "インポート元のファイルにデータが含まれていません", - 732 => "このファイルには内部に他のファイルが含まれているため、挿入できません", - 733 => "テーブルをテーブル自体にインポートすることはできません", - 734 => "このファイルタイプをピクチャとして表示することはできません", - 735 => "このファイルタイプをピクチャとして表示することはできません。ファイルとして挿入および表示 されます", - 736 => "この形式にエクスポートするには、データが大きすぎます。データは切り捨てられます", - 800 => "ファイルをディスク上に作成できません", - 801 => "システムディスクにテンポラリファイルを作成できません", - 802 => "ファイルを開くことができません このエラーの原因は、次の1つ以上です 1 無効なデータベース名 1 ファイルが FileMaker Server で閉じられている 1 無効なアクセス権", - 803 => "ファイルが単独使用に設定されているか、またはホストが見つかりません", - 804 => "ファイルは現在の状態では読み取り専用として開くことができません", - 805 => "ファイルが損傷しています。修復コマンドを使用してください", - 806 => "このバージョンの FileMaker Pro ではファイルを開くことができません", - 807 => "ファイルが FileMaker Pro のファイルではないか、重大な損傷があります", - 808 => "アクセス権情報が壊れているため、ファイルを開くことができません", - 809 => "ディスク/ボリュームがいっぱいです", - 810 => "ディスク/ボリュームがロックされています", - 811 => "テンポラリファイルを FileMaker Pro ファイルとして開くことができません", - 813 => "ネットワーク上でレコードの同期エラーが発生しました", - 814 => "最大数のファイルがすでに開いているため、ファイルを開くことができません", - 815 => "ルックアップファイルを開くことができません", - 816 => "ファイルを変換できません", - 817 => "このソリューションに属していないため、ファイルを開くことができません", - 819 => "リモートファイルのローカルコピーを保存できません", - 820 => "ファイルを閉じる途中です", - 821 => "ホストによって接続解除されました", - 822 => "FMI ファイルが見つかりません。見つからないファイルを再インストールしてください", - 823 => "ファイルをシングルユーザに設定できません。ゲストが接続しています", - 824 => "ファイルが損傷しているか、FileMaker のファイルではありません", - 900 => "スペルチェックのエンジンにエラーが発生しています", - 901 => "スペルチェック用のメイン辞書がインストールされていません", - 902 => "ヘルプシステムを起動できませんでした", - 903 => "共有ファイルではコマンドを使用できません", - 904 => "コマンドは、FileMaker Server がホスト管理しているファイル内でのみ使用できます", - 905 => "アクティブなフィールドが選択されていません。アクティブなフィールドが存在する場合のみコマ ンドを使用することができます", - 906 => "現在のファイルは共有されていません。コマンドは、ファイルが共有されている場合のみ使用する ことができます", - 920 => "スペルチェックエンジンを初期化できません", - 921 => "編集するユーザ辞書をロードできません", - 922 => "ユーザ辞書が見つかりません", - 923 => "ユーザ辞書が読み取り専用です", - 951 => "予期しないエラーが発生しました", - 954 => "サポートされていない XML 文法です", - 955 => "データベース名がありません", - 956 => "データベースセッションが最大数を超過しました", - 957 => "コマンドが競合しています", - 958 => "クエリーに引数がありません", - 1200 => "一般的な計算エラーです", - 1201 => "関数の引数が足りません", - 1202 => "関数の引数が多すぎます", - 1203 => "計算式が未完了です", - 1204 => "数字、テキスト、フィールド名、または「(」を入れてください", - 1205 => "コメントは「*/」で終了できません", - 1206 => "テキストは半角のダブルクォーテーションマークで終わらなければなりません", - 1207 => "カッコが一致していません", - 1208 => "演算子または関数が見つからないか、「(」は指定できません", - 1209 => "名前(フィールド名またはレイアウト名)が見つかりません", - 1210 => "プラグイン関数はすでに登録されています", - 1211 => "この関数では一覧を使用できません", - 1212 => "演算子(+、-、* など)を入れてください", - 1213 => "この変数はすでに Let 関数で定義されています", - 1214 => "AVERAGE、COUNT、EXTEND、GETREPETITION、MAX、MIN、NPV、STDEV、SUM、および GETSUMMARY 関数で、フィールドの値を指定できない部分に式が使われています", - 1215 => "この引数は Get 関数の無効な引数です", - 1216 => "GetSummary 関数の1番目の引数は、集計フィールドのみに限られます", - 1217 => "区分けフィールドが無効です", - 1218 => "数字を評価できません", - 1219 => "フィールド固有の式にフィールドは使用できません", - 1220 => "フィールドタイプは標準にするか、計算する必要があります", - 1221 => "データタイプは数字、日付、時刻、またはタイムスタンプでなければなりません", - 1222 => "計算式を保存できません", - 1223 => "指定された関数はまだ実装されていません", - 1224 => "指定された関数は存在しません", - 1225 => "指定された関数は、このコンテキストではサポートされていません", - 1400 => "ODBC クライアントドライバの初期化に失敗しました。ODBC クライアントドライバが適切にイン ストールされていることを確認してください", - 1401 => "環境の割り当てに失敗しました(ODBC)", - 1402 => "環境の解放に失敗しました(ODBC)", - 1403 => "切断に失敗しました(ODBC)", - 1404 => "接続の割り当てに失敗しました(ODBC)", - 1405 => "接続の解放に失敗しました(ODBC)", - 1406 => "SQL API のチェックに失敗しました(ODBC)", - 1407 => "ステートメントの割り当てに失敗しました(ODBC)", - 1408 => "拡張エラー(ODBC)", - 1409 => "拡張エラー(ODBC)", - 1410 => "拡張エラー(ODBC)", - 1411 => "拡張エラー(ODBC)", - 1412 => "拡張エラー(ODBC)", - 1413 => "拡張エラー(ODBC)", - 1450 => "PHP アクセス権を拡張する操作が必要です", - 1451 => "現在のファイルをリモートにする操作が必要です", - 1501 => "SMTP の認証に失敗しました", - 1502 => "SMTP サーバーによって接続が拒否されました", - 1503 => "SSL でエラーが発生しました", - 1504 => "SMTP サーバーの接続を暗号化する必要があります", - 1505 => "指定された認証方法は SMTP サーバーではサポートされていません", - 1506 => "メールは正常に送信されませんでした", - 1507 => "SMTP サーバーにログインできませんでした" - + '-1' => "原因不明のエラー", + 0 => "エラーなし", + 1 => "ユーザによるキャンセル", + 2 => "メモリエラー", + 3 => "コマンドが使用できません(たとえば誤ったオペレーティングシステム、誤ったモードなど)", + 4 => "コマンドが見つかりません", + 5 => "コマンドが無効です(たとえば、[フィールド設定] スクリプトステップに計算式が指定されていな い場合など)", + 6 => "ファイルが読み取り専用です", + 7 => "メモリ不足", + 8 => "空白の結果", + 9 => "アクセス権が不十分です", + 10 => "要求されたデータが見つかりません", + 11 => "名前が有効ではありません", + 12 => "名前がすでに存在します", + 13 => "ファイルまたはオブジェクトが使用中です", + 14 => "範囲外", + 15 => "0で割ることができません", + 16 => "処理に失敗したため、再試行が必要です(たとえば、ユーザクエリーなど)", + 17 => "外国語の文字セットの UTF-16 への変換に失敗しました", + 18 => "続行するには、クライアントはアカウント情報を指定する必要があります", + 19 => "文字列に A から Z、a から z、0 から 9(ASCII)以外の文字が含まれています", + 20 => "コマンドまたは操作がスクリプトトリガによってキャンセルされました", + 100 => "ファイルが見つかりません", + 101 => "レコードが見つかりません", + 102 => "フィールドが見つかりません", + 103 => "リレーションシップが見つかりません", + 104 => "スクリプトが見つかりません", + 105 => "レイアウトが見つかりません", + 106 => "テーブルが見つかりません", + 107 => "索引が見つかりません", + 108 => "値一覧が見つかりません", + 109 => "アクセス権セットが見つかりません", + 110 => "関連テーブルが見つかりません", + 111 => "フィールドの繰り返しが無効です", + 112 => "ウインドウが見つかりません", + 113 => "関数が見つかりません", + 114 => "ファイル参照が見つかりません", + 115 => "メニューセットが見つかりません", + 116 => "レイアウトオブジェクトが見つかりません", + 117 => "データソースが見つかりません", + 130 => "ファイルが損傷しているか見つからないため、再インストールする必要があります", + 131 => "言語パックファイルが見つかりません(テンプレートなど)", + 200 => "レコードアクセスが拒否されました", + 201 => "フィールドを変更できません", + 202 => "フィールドアクセスが拒否されました", + 203 => "ファイルに印刷するレコードがないか、入力したパスワードでは印刷できません", + 204 => "ソート優先順位に指定されたフィールドにアクセスできません", + 205 => "ユーザに新規レコードを作成するアクセス権がありません。既存のデータはインポートしたデータ で上書きされます", + 206 => "ユーザにパスワードの変更アクセス権がないか、変更可能なファイルではありません", + 207 => "ユーザにデータベーススキーマを変更する十分なアクセス権がないか、変更可能なファイルではあ りません", + 208 => "パスワードに十分な文字が含まれていません", + 209 => "既存のパスワードと新規パスワードを同一にすることはできません", + 210 => "ユーザアカウントが非アクティブです", + 211 => "パスワードが期限切れです", + 212 => "ユーザアカウントまたはパスワードが無効です。再試行してください", + 213 => "ユーザアカウントまたはパスワードが存在しません", + 214 => "ログイン試行回数が多すぎます", + 215 => "管理者権限は複製できません", + 216 => "ゲストアカウントは複製できません", + 217 => "ユーザに管理者アカウントを変更する十分なアクセス権がありません", + 300 => "ファイルがロックされているか、使用中です", + 301 => "別のユーザがレコードを使用中です", + 302 => "別のユーザがテーブルを使用中です", + 303 => "別のユーザがデータベーススキーマを使用中です", + 304 => "別のユーザがレイアウトを使用中です", + 306 => "レコード修正 ID が一致しません", + 400 => "検索条件が空です", + 401 => "検索条件に一致するレコードがありません", + 402 => "選択したフィールドはルックアップの照合フィールドではありません", + 403 => "評価版の FileMaker Pro に設定されている最大レコード数の制限を超過しています", + 404 => "ソート優先順位が無効です", + 405 => "指定したレコード数が除外可能なレコード数を超過しています", + 406 => "全置換またはシリアル番号の再入力に指定された条件が無効です", + 407 => "片方または両方の照合フィールドが欠けています(無効なリレーションシップ)", + 408 => "指定されたフィールドのデータが不適切なため、この処理を実行できません", + 409 => "インポート順が無効です", + 410 => "エスクポート順が無効です", + 412 => "ファイルの修復に、誤ったバージョンの FileMaker Pro が使用されました", + 413 => "指定されたフィールドのフィールドタイプが不適切です", + 414 => "レイアウトに結果を表示できません", + 415 => "1つまたは複数の必要な関連レコードが使用できません", + 416 => "データソーステーブルからプライマリキーが必要です", + 417 => "データベースが、サポートされているデータソースではありません", + 500 => "日付の値が入力値の制限を満たしていません", + 501 => "時刻の値が入力値の制限を満たしていません", + 502 => "数字の値が入力値の制限を満たしていません", + 503 => "フィールドの値が入力値の制限オプションに指定されている範囲内に入っていません", + 504 => "フィールドの値が入力値の制限オプションで要求されているようにユニークな値になっていません", + 505 => "フィールドの値が入力値の制限オプションで要求されているようにデータベースファイル内の既存 値になっていません", + 506 => "フィールドの値が入力値の制限オプションに指定されている値一覧に含まれていません", + 507 => "フィールドの値が入力値の制限オプションに指定されている計算式を満たしません", + 508 => "検索モードに無効な値が入力されました", + 509 => "フィールドに有効な値が必要です", + 510 => "関連する値が空であるか、使用できません", + 511 => "フィールド内の値が最大文字数を超過しました", + 512 => "レコードがすでに別のユーザによって変更されています", + 513 => "レコードを作成するには、レコードの少なくとも1つのフィールドに値がある必要があります", + 600 => "印刷エラーが発生しました", + 601 => "ヘッダとフッタの高さを加算するとページの高さを超えます", + 602 => "現在の段数設定ではボディ部分がページ内に収まりません", + 603 => "印刷接続が遮断されました", + 700 => "インポートできないファイルタイプです", + 706 => "EPSF ファイルにプレビューイメージがありません", + 707 => "グラフィックの変換ファイルが見つかりません", + 708 => "ファイルをインポートできないか、ファイルをインポートするにはカラーのコンピュータが必要で す", + 709 => "QuickTime ムービーのインポートに失敗しました", + 710 => "データベースファイルが読み取り専用になっているため QuickTime ファイルの参照を更新できませ ん", + 711 => "インポートの変換ファイルが見つかりません", + 714 => "入力したパスワードでは設定されている権限が不足しているためこの操作は認められていません", + 715 => "指定された Excel ワークシートまたは名前の付いた範囲がありません", + 716 => "ODBC インポートでは、DELETE、INSERT、または UPDATE を使用する SQL クエリーは使用でき ません", + 717 => "インポートまたはエクスポートを続行するための十分な XML/XSLT 情報がありません", + 718 => "(Xerces からの)XML ファイルの解析エラーです", + 719 => "(Xalan からの)XSL を使用した XML 変換エラーです", + 720 => "エクスポート時のエラー。対象のドキュメントフォーマットでは繰り返しフィールドはサポートさ れていません", + 721 => "パーサまたはトランスフォーマで原因不明のエラーが発生しました", + 722 => "フィールドのないファイルにデータをインポートすることはできません", + 723 => "インポート先のテーブルでレコードを追加または変更する権限がありません", + 724 => "インポート先のテーブルにレコードを追加する権限がありません", + 725 => "インポート先のテーブルでレコードを変更する権限がありません", + 726 => "インポートファイルのレコードの方がインポート先のテーブルのレコードよりも多くなっていま す。一部のレコードはインポートされません", + 727 => "インポート先のテーブルのレコードの方がインポートファイルのレコードよりも多くなっていま す。一部のレコードは更新されません", + 729 => "インポート中にエラーが発生しました。レコードをインポートすることができません", + 730 => "サポートされていない Excel のバージョンです。ファイルを Excel 7.0(Excel 95)、Excel 97、2000、 XPまたは2007 のフォーマットに変換して、もう一度実行してください", + 731 => "インポート元のファイルにデータが含まれていません", + 732 => "このファイルには内部に他のファイルが含まれているため、挿入できません", + 733 => "テーブルをテーブル自体にインポートすることはできません", + 734 => "このファイルタイプをピクチャとして表示することはできません", + 735 => "このファイルタイプをピクチャとして表示することはできません。ファイルとして挿入および表示 されます", + 736 => "この形式にエクスポートするには、データが大きすぎます。データは切り捨てられます", + 800 => "ファイルをディスク上に作成できません", + 801 => "システムディスクにテンポラリファイルを作成できません", + 802 => "ファイルを開くことができません このエラーの原因は、次の1つ以上です 1 無効なデータベース名 1 ファイルが FileMaker Server で閉じられている 1 無効なアクセス権", + 803 => "ファイルが単独使用に設定されているか、またはホストが見つかりません", + 804 => "ファイルは現在の状態では読み取り専用として開くことができません", + 805 => "ファイルが損傷しています。修復コマンドを使用してください", + 806 => "このバージョンの FileMaker Pro ではファイルを開くことができません", + 807 => "ファイルが FileMaker Pro のファイルではないか、重大な損傷があります", + 808 => "アクセス権情報が壊れているため、ファイルを開くことができません", + 809 => "ディスク/ボリュームがいっぱいです", + 810 => "ディスク/ボリュームがロックされています", + 811 => "テンポラリファイルを FileMaker Pro ファイルとして開くことができません", + 813 => "ネットワーク上でレコードの同期エラーが発生しました", + 814 => "最大数のファイルがすでに開いているため、ファイルを開くことができません", + 815 => "ルックアップファイルを開くことができません", + 816 => "ファイルを変換できません", + 817 => "このソリューションに属していないため、ファイルを開くことができません", + 819 => "リモートファイルのローカルコピーを保存できません", + 820 => "ファイルを閉じる途中です", + 821 => "ホストによって接続解除されました", + 822 => "FMI ファイルが見つかりません。見つからないファイルを再インストールしてください", + 823 => "ファイルをシングルユーザに設定できません。ゲストが接続しています", + 824 => "ファイルが損傷しているか、FileMaker のファイルではありません", + 900 => "スペルチェックのエンジンにエラーが発生しています", + 901 => "スペルチェック用のメイン辞書がインストールされていません", + 902 => "ヘルプシステムを起動できませんでした", + 903 => "共有ファイルではコマンドを使用できません", + 904 => "コマンドは、FileMaker Server がホスト管理しているファイル内でのみ使用できます", + 905 => "アクティブなフィールドが選択されていません。アクティブなフィールドが存在する場合のみコマ ンドを使用することができます", + 906 => "現在のファイルは共有されていません。コマンドは、ファイルが共有されている場合のみ使用する ことができます", + 920 => "スペルチェックエンジンを初期化できません", + 921 => "編集するユーザ辞書をロードできません", + 922 => "ユーザ辞書が見つかりません", + 923 => "ユーザ辞書が読み取り専用です", + 951 => "予期しないエラーが発生しました", + 954 => "サポートされていない XML 文法です", + 955 => "データベース名がありません", + 956 => "データベースセッションが最大数を超過しました", + 957 => "コマンドが競合しています", + 958 => "クエリーに引数がありません", + 1200 => "一般的な計算エラーです", + 1201 => "関数の引数が足りません", + 1202 => "関数の引数が多すぎます", + 1203 => "計算式が未完了です", + 1204 => "数字、テキスト、フィールド名、または「(」を入れてください", + 1205 => "コメントは「*/」で終了できません", + 1206 => "テキストは半角のダブルクォーテーションマークで終わらなければなりません", + 1207 => "カッコが一致していません", + 1208 => "演算子または関数が見つからないか、「(」は指定できません", + 1209 => "名前(フィールド名またはレイアウト名)が見つかりません", + 1210 => "プラグイン関数はすでに登録されています", + 1211 => "この関数では一覧を使用できません", + 1212 => "演算子(+、-、* など)を入れてください", + 1213 => "この変数はすでに Let 関数で定義されています", + 1214 => "AVERAGE、COUNT、EXTEND、GETREPETITION、MAX、MIN、NPV、STDEV、SUM、および GETSUMMARY 関数で、フィールドの値を指定できない部分に式が使われています", + 1215 => "この引数は Get 関数の無効な引数です", + 1216 => "GetSummary 関数の1番目の引数は、集計フィールドのみに限られます", + 1217 => "区分けフィールドが無効です", + 1218 => "数字を評価できません", + 1219 => "フィールド固有の式にフィールドは使用できません", + 1220 => "フィールドタイプは標準にするか、計算する必要があります", + 1221 => "データタイプは数字、日付、時刻、またはタイムスタンプでなければなりません", + 1222 => "計算式を保存できません", + 1223 => "指定された関数はまだ実装されていません", + 1224 => "指定された関数は存在しません", + 1225 => "指定された関数は、このコンテキストではサポートされていません", + 1400 => "ODBC クライアントドライバの初期化に失敗しました。ODBC クライアントドライバが適切にイン ストールされていることを確認してください", + 1401 => "環境の割り当てに失敗しました(ODBC)", + 1402 => "環境の解放に失敗しました(ODBC)", + 1403 => "切断に失敗しました(ODBC)", + 1404 => "接続の割り当てに失敗しました(ODBC)", + 1405 => "接続の解放に失敗しました(ODBC)", + 1406 => "SQL API のチェックに失敗しました(ODBC)", + 1407 => "ステートメントの割り当てに失敗しました(ODBC)", + 1408 => "拡張エラー(ODBC)", + 1409 => "拡張エラー(ODBC)", + 1410 => "拡張エラー(ODBC)", + 1411 => "拡張エラー(ODBC)", + 1412 => "拡張エラー(ODBC)", + 1413 => "拡張エラー(ODBC)", + 1450 => "PHP アクセス権を拡張する操作が必要です", + 1451 => "現在のファイルをリモートにする操作が必要です", + 1501 => "SMTP の認証に失敗しました", + 1502 => "SMTP サーバーによって接続が拒否されました", + 1503 => "SSL でエラーが発生しました", + 1504 => "SMTP サーバーの接続を暗号化する必要があります", + 1505 => "指定された認証方法は SMTP サーバーではサポートされていません", + 1506 => "メールは正常に送信されませんでした", + 1507 => "SMTP サーバーにログインできませんでした" + }; sub new { - my $class = shift; - $class = ref($class) || $class; + my $class = shift; + $class = ref($class) || $class; - my $self = { }; - return bless $self, $class; + my $self = { }; + return bless $self, $class; } sub get_string { - my ($self, $error_code) = @_; - return $error_codes->{$error_code}; + my ($self, $error_code) = @_; + return $error_codes->{$error_code}; } -1; # End of Net::FileMaker::Error::JA::XML \ No newline at end of file +1; # End of Net::FileMaker::Error::JA::XML diff --git a/lib/Net/FileMaker/Error/JA/XSLT.pm b/lib/Net/FileMaker/Error/JA/XSLT.pm index 1c6d230..6af16ae 100644 --- a/lib/Net/FileMaker/Error/JA/XSLT.pm +++ b/lib/Net/FileMaker/Error/JA/XSLT.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::Error::JA::XSLT; +package + Net::FileMaker::Error::JA::XSLT; use strict; use warnings; @@ -21,57 +22,57 @@ L my $error_codes = { - '-1' => "原因不明のエラー", - 0 => "エラーなし", - 10000 => "無効なヘッダ名", - 10001 => "無効な HTTP ステータスコード", - 10100 => "原因不明のセッションエラー",, - 10101 => "要求されたセッション名はすでに使用されています", - 10102 => "セッションにアクセスできませんでした。存在しない可能性があります", - 10103 => "セッションがタイムアウトしました", - 10104 => "指定されたセッションオブジェクトは存在しません", - 10200 => "原因不明のメッセージングエラー", - 10201 => "メッセージの書式設定エラー", - 10202 => "メッセージの SMTP フィールドのエラー", - 10203 => "メッセージの「To」フィールドのエラー", - 10204 => "メッセージの「From」フィールドのエラー", - 10205 => "メッセージの「CC」フィールドのエラー", - 10206 => "メッセージの「BCC」フィールドのエラー", - 10207 => "メッセージの「Subject」フィールドのエラー", - 10208 => "メッセージの「Reply-To」フィールドのエラー", - 10209 => "メッセージの本文のエラー", - 10210 => "再帰メールエラー - 電子メール用の XSLT スタイルシート内で send_email() を呼び出そうとしました", - 10211 => "SMTP 認証エラー - ログインに失敗したか、間違ったタイプの認証が指定されています", - 10212 => "無効な関数の使用法 - 電子メール用の XSLT スタイルシート内で set_header()、set_status_code()、ま たは set_cookie() を呼び出そうとしました", - 10213 => "SMTP サーバーが無効であるか動作していません", - 10300 => "原因不明の書式設定エラー", - 10301 => "無効な日付または時刻書式", - 10302 => "無効な日付書式", - 10303 => "無効な時刻書式", - 10304 => "無効な曜日書式", - 10305 => "不適切な形式の日付または時刻文字列", - 10306 => "不適切な形式の日付文字列", - 10307 => "不適切な形式の時刻文字列", - 10308 => "不適切な形式の曜日文字列", - 10309 => "サポートされていないテキストエンコード", - 10310 => "無効な URL エンコード", - 10311 => "正規表現パターンのエラー" + '-1' => "原因不明のエラー", + 0 => "エラーなし", + 10000 => "無効なヘッダ名", + 10001 => "無効な HTTP ステータスコード", + 10100 => "原因不明のセッションエラー",, + 10101 => "要求されたセッション名はすでに使用されています", + 10102 => "セッションにアクセスできませんでした。存在しない可能性があります", + 10103 => "セッションがタイムアウトしました", + 10104 => "指定されたセッションオブジェクトは存在しません", + 10200 => "原因不明のメッセージングエラー", + 10201 => "メッセージの書式設定エラー", + 10202 => "メッセージの SMTP フィールドのエラー", + 10203 => "メッセージの「To」フィールドのエラー", + 10204 => "メッセージの「From」フィールドのエラー", + 10205 => "メッセージの「CC」フィールドのエラー", + 10206 => "メッセージの「BCC」フィールドのエラー", + 10207 => "メッセージの「Subject」フィールドのエラー", + 10208 => "メッセージの「Reply-To」フィールドのエラー", + 10209 => "メッセージの本文のエラー", + 10210 => "再帰メールエラー - 電子メール用の XSLT スタイルシート内で send_email() を呼び出そうとしました", + 10211 => "SMTP 認証エラー - ログインに失敗したか、間違ったタイプの認証が指定されています", + 10212 => "無効な関数の使用法 - 電子メール用の XSLT スタイルシート内で set_header()、set_status_code()、ま たは set_cookie() を呼び出そうとしました", + 10213 => "SMTP サーバーが無効であるか動作していません", + 10300 => "原因不明の書式設定エラー", + 10301 => "無効な日付または時刻書式", + 10302 => "無効な日付書式", + 10303 => "無効な時刻書式", + 10304 => "無効な曜日書式", + 10305 => "不適切な形式の日付または時刻文字列", + 10306 => "不適切な形式の日付文字列", + 10307 => "不適切な形式の時刻文字列", + 10308 => "不適切な形式の曜日文字列", + 10309 => "サポートされていないテキストエンコード", + 10310 => "無効な URL エンコード", + 10311 => "正規表現パターンのエラー" }; sub new { - my $class = shift; - $class = ref($class) || $class; + my $class = shift; + $class = ref($class) || $class; - my $self = { }; - return bless $self, $class; + my $self = { }; + return bless $self, $class; } sub get_string { - my ($self, $error_code) = @_; - return $error_codes->{$error_code}; + my ($self, $error_code) = @_; + return $error_codes->{$error_code}; } -1; # End of Net::FileMaker::Error::JA::XSLT \ No newline at end of file +1; # End of Net::FileMaker::Error::JA::XSLT diff --git a/lib/Net/FileMaker/XML.pm b/lib/Net/FileMaker/XML.pm index 5712088..c206a75 100644 --- a/lib/Net/FileMaker/XML.pm +++ b/lib/Net/FileMaker/XML.pm @@ -11,14 +11,6 @@ use XML::Twig; Net::FileMaker::XML - Interact with FileMaker Server's XML Interface. -=head1 VERSION - -Version 0.062 - -=cut - -our $VERSION = 0.062; - =head1 SYNOPSIS This module provides the interface for communicating with FileMaker Server's XML service. @@ -50,29 +42,29 @@ Creates a new object. The specified must be a valid address or host name. sub new { - my($class, %args) = @_; + my($class, %args) = @_; - # If the protocol isn't specified, let's assume it's just HTTP. - if($args{host} !~/^http/x) - { - $args{host} = 'http://'.$args{host}; - } + # If the protocol isn't specified, let's assume it's just HTTP. + if($args{host} !~/^http/x) + { + $args{host} = 'http://'.$args{host}; + } require LWP::UserAgent; - my $self = { - host => $args{host}, - ua => LWP::UserAgent->new, - xml => XML::Twig->new, - uri => URI->new($args{host}), - resultset => '/fmi/xml/fmresultset.xml', # Entirely for dbnames(); - }; - - if($args{error}) - { - $self->{error} = Net::FileMaker::Error->new(lang => $args{error}, type => 'XML'); - } + my $self = { + host => $args{host}, + ua => LWP::UserAgent->new, + xml => XML::Twig->new, + uri => URI->new($args{host}), + resultset => '/fmi/xml/fmresultset.xml', # Entirely for dbnames(); + }; + + if($args{error}) + { + $self->{error} = Net::FileMaker::Error->new(lang => $args{error}, type => 'XML'); + } bless $self , $class; - return $self; + return $self; } @@ -84,41 +76,43 @@ Initiates a new database object for querying data in the databse. sub database { - my($self, %args) = @_; - - require Net::FileMaker::XML::Database; - return Net::FileMaker::XML::Database->new( - host => $self->{host}, - db => $args{db}, - user => $args{user} || '', - pass => $args{pass} || '' - ); + my($self, %args) = @_; + + require Net::FileMaker::XML::Database; + return Net::FileMaker::XML::Database->new( + host => $self->{host}, + db => $args{db}, + user => $args{user} || '', + pass => $args{pass} || '' + ); } =head2 dbnames -Returns an arrayref containing all XML/XSLT enabled databases for a given host. This method requires no authentication. +Returns an arrayref containing all XML/XSLT enabled databases for a given host. +This method requires no authentication. =cut sub dbnames { - my $self = shift; - my $xml = $self->_request( - resultset => $self->{resultset}, - query =>'-dbnames' - ); + my $self = shift; + my $xml = $self->_request( + resultset => $self->{resultset}, + query =>'-dbnames' + ); - return $self->_compose_arrayref('DATABASE_NAME', $xml); + return $self->_compose_arrayref('DATABASE_NAME', $xml); } =head1 COMPATIBILITY -This distrobution is actively tested against FileMaker Advanced Server 10.0.1.59 and 11.0.1.95. -Older versions are not tested at present, but feedback is welcome. See the messages present in the test suite on how to setup -tests against your server. +This distrobution is actively tested against FileMaker Advanced Server 10.0.1.59 +and 11.0.1.95. Older versions are not tested at present, but feedback is +welcome. See the messages present in the test suite on how to setup tests +against your server. =head1 SEE ALSO @@ -139,10 +133,11 @@ sub _request $uri->path($args{resultset}); my $url; - # This kind of defeats the purpose of using URI to begin with, but this fault has been reported - # on rt.cpan.org for over 2 years and many releases with no fix. + # This kind of defeats the purpose of using URI to begin with, but this + # fault has been reported on rt.cpan.org for over 2 years and many releases + # with no fix. if($args{params}) - { + { $uri->query_form(%{$args{params}}); $url = $uri->as_string."&".$args{query}; } @@ -160,14 +155,14 @@ sub _request my $res = $self->{ua}->request($req); - my $xml = $self->{xml}->parse($res->content); - my $xml_data = $xml->simplify; + my $xml = $self->{xml}->parse($res->content); + my $xml_data = $xml->simplify; - # Inject localised error message - if($self->{error}) - { - $xml_data->{error}->{message} = $self->{error}->get_string($xml_data->{error}->{code}); - } + # Inject localised error message + if($self->{error}) + { + $xml_data->{error}->{message} = $self->{error}->get_string($xml_data->{error}->{code}); + } $xml_data->{http_response} = $res; return $xml_data; @@ -180,23 +175,23 @@ sub _request # A common occurance is recomposing response data so unnecessary structure is removed. sub _compose_arrayref { - my ($self, $fieldname, $xml) = @_; - - if(ref($xml->{resultset}->{record}) eq 'HASH') - { - return $xml->{resultset}->{record}->{field}->{$fieldname}->{data}; - } - elsif(ref($xml->{resultset}->{record}) eq 'ARRAY') - { - my @output; - - for my $record (@{$xml->{resultset}->{record}}) - { - push @output, $record->{field}->{$fieldname}->{data}; - } - - return \@output; - } + my ($self, $fieldname, $xml) = @_; + + if(ref($xml->{resultset}->{record}) eq 'HASH') + { + return $xml->{resultset}->{record}->{field}->{$fieldname}->{data}; + } + elsif(ref($xml->{resultset}->{record}) eq 'ARRAY') + { + my @output; + + for my $record (@{$xml->{resultset}->{record}}) + { + push @output, $record->{field}->{$fieldname}->{data}; + } + + return \@output; + } } @@ -209,26 +204,29 @@ sub _compose_arrayref sub _assert_param { - my($self, $unclean_param, $acceptable_params) = @_; - my $param; - # if the param is of private type '-something' let's check, otherwise skip 'cause it could be the name of a field - # todo: we might add a strict control to avoid passing others params than the ones with "-" like in findall etc + my($self, $unclean_param, $acceptable_params) = @_; + my $param; + # if the param is of private type '-something' let's check, otherwise skip + # 'cause it could be the name of a field + # TODO: we might add a strict control to avoid passing others params than + # the ones with "-" like in findall etc + if($unclean_param =~ /^-.+$/x) - { - if($unclean_param =~/$acceptable_params/x) - { - $param = $unclean_param; - } - else - { - # TODO: Localise this error message - carp "Invalid parameter specified - $unclean_param"; - } + { + if($unclean_param =~/$acceptable_params/x) + { + $param = $unclean_param; + } + else + { + # TODO: Localise this error message + carp "Invalid parameter specified - $unclean_param"; + } }else{ - $param = $unclean_param; + $param = $unclean_param; } - return $param; + return $param; } @@ -238,13 +236,13 @@ sub _assert_param sub _assert_params { - my ($self , %args) = @_; - - my $params = $args{def_params}; - my $acceptable_params = $args{acceptable_params}; - my $type = $args{type}; - - if($args{params} && ref($args{params}) eq 'HASH') + my ($self , %args) = @_; + + my $params = $args{def_params}; + my $acceptable_params = $args{acceptable_params}; + my $type = $args{type}; + + if($args{params} && ref($args{params}) eq 'HASH') { for my $param(keys %{$args{params}}) { @@ -255,7 +253,8 @@ sub _assert_params } else { - $params->{$param} = $args{params}->{$param} if $self->_assert_param($param, $acceptable_params->{$type}); + $params->{$param} = $args{params}->{$param} + if $self->_assert_param($param, $acceptable_params->{$type}); } } } diff --git a/lib/Net/FileMaker/XML/Database.pm b/lib/Net/FileMaker/XML/Database.pm index ba70715..49c54e6 100644 --- a/lib/Net/FileMaker/XML/Database.pm +++ b/lib/Net/FileMaker/XML/Database.pm @@ -6,34 +6,27 @@ use Net::FileMaker::XML::ResultSet; use Carp; use base qw(Net::FileMaker::XML); -# -# Particular methods have specific parameters that are optional, but need to be validated to mitigate sending -# bad parameters to the server. + +# Particular methods have specific parameters that are optional, but need to be +# validated to mitigate sending bad parameters to the server. my $acceptable_params = { - 'find' => '-recid|-lop|-op|-max|-skip|-sortorder|-sortfield|-script|-script\.prefind|-script\.presort', - 'findall' => '-recid|-lop|-op|-max|-skip|-sortorder|-sortfield|-script|-script\.prefind|-script\.presort', - 'findany' => '-recid|-lop|-op|-max|-skip|-sortorder|-sortfield|-script|-script\.prefind|-script\.presort', - 'delete' => '-db|-lay|-recid|-script', - 'dup' => '-db|-lay|-recid|-script', - 'edit' => '-db|-lay|-recid|-modid|-script', - 'new' => '-db|-lay|-script' + 'find' => '-recid|-lop|-op|-max|-skip|-sortorder|-sortfield|-script|-script\.prefind|-script\.presort', + 'findall' => '-recid|-lop|-op|-max|-skip|-sortorder|-sortfield|-script|-script\.prefind|-script\.presort', + 'findany' => '-recid|-lop|-op|-max|-skip|-sortorder|-sortfield|-script|-script\.prefind|-script\.presort', + 'delete' => '-db|-lay|-recid|-script', + 'dup' => '-db|-lay|-recid|-script', + 'edit' => '-db|-lay|-recid|-modid|-script', + 'new' => '-db|-lay|-script' }; =head1 NAME Net::FileMaker::XML::Database -=head1 VERSION - -Version 0.062 - -=cut - -our $VERSION = 0.062; - =head1 SYNOPSIS -This module handles all the tasks with XML data. Don't call this module directly, instead use L. +This module handles all the tasks with XML data. Don't call this module +directly, instead use L. use Net::FileMaker::XML; my $fm = Net::FileMaker::XML->new(host => $host); @@ -50,21 +43,21 @@ This module handles all the tasks with XML data. Don't call this module directly sub new { - my($class, %args) = @_; - - my $self = { - host => $args{host}, - db => $args{db}, - user => $args{user}, - pass => $args{pass}, - resultset => '/fmi/xml/fmresultset.xml', + my($class, %args) = @_; + + my $self = { + host => $args{host}, + db => $args{db}, + user => $args{user}, + pass => $args{pass}, + resultset => '/fmi/xml/fmresultset.xml', ua => LWP::UserAgent->new, xml => XML::Twig->new, uri => URI->new($args{host}), - }; + }; bless $self , $class; - return $self; + return $self; } =head2 layoutnames @@ -75,7 +68,7 @@ Returns an arrayref containing layouts accessible for the respective database. sub layoutnames { - my $self = shift; + my $self = shift; my $xml = $self->_request( user => $self->{user}, pass => $self->{pass}, @@ -85,7 +78,7 @@ sub layoutnames ); - return $self->_compose_arrayref('LAYOUT_NAME', $xml); + return $self->_compose_arrayref('LAYOUT_NAME', $xml); } =head2 scriptnames @@ -96,7 +89,7 @@ Returns an arrayref containing scripts accessible for the respective database. sub scriptnames { - my $self = shift; + my $self = shift; my $xml = $self->_request( user => $self->{user}, pass => $self->{pass}, @@ -106,94 +99,109 @@ sub scriptnames ); - return $self->_compose_arrayref('SCRIPT_NAME', $xml); + return $self->_compose_arrayref('SCRIPT_NAME', $xml); } =head2 find(layout => $layout, params => { parameters }) -Returns Net::FileMaker::XML::ResultSet for a specific database and layout. +Returns a L for a specific database and layout. =cut sub find { - my ($self, %args) = @_; + my ($self, %args) = @_; my $params = { '-lay' => $args{layout}, '-db' => $self->{db} }; - $params = $self->_assert_params(def_params => $params ,params => $args{params} , acceptable_params => $acceptable_params , type => 'find'); - - my $xml = $self->_request( - resultset => $self->{resultset}, - user => $self->{user}, - pass => $self->{pass}, - query => '-find', - params => $params - ); - - return Net::FileMaker::XML::ResultSet->new(rs => $xml , db => $self); + $params = $self->_assert_params( + type => 'find', + def_params => $params, + params => $args{params}, + acceptable_params => $acceptable_params, + ); + + my $xml = $self->_request( + resultset => $self->{resultset}, + user => $self->{user}, + pass => $self->{pass}, + query => '-find', + params => $params + ); + + return Net::FileMaker::XML::ResultSet->new(rs => $xml , db => $self); } =head2 findall(layout => $layout, params => { parameters }, nocheck => 1) -Returns a Net::FileMaker::XML::ResultSet of all rows on a specific database and layout. - -nocheck is an optional argument that will skip checking of parameters if set to 1. +Returns a L of all rows on a specific database +and layout. C is an optional argument that will skip checking of +parameters if set to 1. =cut sub findall { - my ($self, %args) = @_; + my ($self, %args) = @_; - my $params = { - '-lay' => $args{layout}, - '-db' => $self->{db} - }; + my $params = { + '-lay' => $args{layout}, + '-db' => $self->{db} + }; - $params = $self->_assert_params(def_params => $params ,params => $args{params} , acceptable_params => $acceptable_params, type => 'findall'); + $params = $self->_assert_params( + type => 'findall', + def_params => $params, + params => $args{params}, + acceptable_params => $acceptable_params + ); - my $xml = $self->_request( - resultset => $self->{resultset}, - user => $self->{user}, - pass => $self->{pass}, - query => '-findall', - params => $params - ); + my $xml = $self->_request( + resultset => $self->{resultset}, + user => $self->{user}, + pass => $self->{pass}, + query => '-findall', + params => $params + ); return Net::FileMaker::XML::ResultSet->new(rs => $xml , db => $self); } =head2 findany(layout => $layout, params => { parameters }, nocheck => 1) -Returns Net::FileMaker::XML::ResultSet of random rows on a specific database and layout. - -nocheck is an optional argument that will skip checking of parameters if set to 1. +Returns a L of random rows on a specific +database and layout. C is an optional argument that will skip checking +of parameters if set to 1. =cut sub findany { - my ($self, %args) = @_; + my ($self, %args) = @_; - my $params = { - '-lay' => $args{layout}, - '-db' => $self->{db} - }; + my $params = { + '-lay' => $args{layout}, + '-db' => $self->{db} + }; - $params = $self->_assert_params(def_params => $params ,params => $args{params} , acceptable_params => $acceptable_params, type => 'findany'); + $params = $self->_assert_params( + type => 'findany', + def_params => $params, + params => $args{params}, + acceptable_params => $acceptable_params, + ); - my $xml = $self->_request( - resultset => $self->{resultset}, - user => $self->{user}, - pass => $self->{pass}, - query => '-findany', - params => $params - ); + my $xml = $self->_request( + resultset => $self->{resultset}, + user => $self->{user}, + pass => $self->{pass}, + query => '-findany', + params => $params + ); return Net::FileMaker::XML::ResultSet->new(rs => $xml , db => $self); } @@ -202,12 +210,12 @@ sub findany =head2 edit(layout => $layout , recid => $recid , params => { params }) -Updates the row with the fieldname/value pairs passed to params, -returns an L object. +Updates the row with the fieldname/value pairs passed to params. +Returns a L object. =cut -#todo: add tests to /t/01_xml +#TODO: add tests to /t/01_xml sub edit { @@ -222,7 +230,12 @@ sub edit croak 'recid must be defined' if(! defined $args{recid}); $params->{'-recid'} = $args{recid}; - $params = $self->_assert_params(def_params => $params ,params => $args{params} , acceptable_params => $acceptable_params, type => 'edit'); + $params = $self->_assert_params( + type => 'edit', + def_params => $params, + params => $args{params}, + acceptable_params => $acceptable_params + ); my $xml = $self->_request( resultset => $self->{resultset}, @@ -237,7 +250,8 @@ sub edit =head2 remove(layout => $layout , recid => $recid , params => { params }) -Deletes the record with that specific record id and returns an N::F::X::ResultSet object +Deletes the record with that specific record id and returns a +L object. =cut @@ -254,7 +268,12 @@ sub remove croak 'recid must be defined' if(! defined $args{recid}); $params->{'-recid'} = $args{recid}; - $params = $self->_assert_params(def_params => $params ,params => $args{params} , acceptable_params => $acceptable_params, type => 'delete'); + $params = $self->_assert_params( + type => 'delete', + def_params => $params, + params => $args{params}, + acceptable_params => $acceptable_params + ); my $xml = $self->_request( resultset => $self->{resultset}, @@ -273,8 +292,8 @@ sub remove Creates a new record and populates that record with the fieldname/value pairs passed to params. -Returns an N::F::X::ResultSet object - +Returns an L object. + =cut sub insert @@ -286,7 +305,12 @@ sub insert '-db' => $self->{db} }; - $params = $self->_assert_params(def_params => $params ,params => $args{params} , acceptable_params => $acceptable_params , type => 'new'); + $params = $self->_assert_params( + type => 'new', + def_params => $params, + params => $args{params}, + acceptable_params => $acceptable_params + ); my $xml = $self->_request( resultset => $self->{resultset}, @@ -309,18 +333,22 @@ Returns a scalar with the total rows for a given layout. sub total_rows { - my($self, %args) = @_; - - # Just do a findall with 1 record and parse the result. This might break on an empty database. - my $xml = $self->_request( - user => $self->{user}, - pass => $self->{pass}, - resultset => $self->{resultset}, - params => {'-db' => $self->{db}, '-lay' => $args{layout}, '-max' => '1' }, - query => '-findall' - ); - - return $xml; + my($self, %args) = @_; + + # Just do a findall with 1 record and parse the result. This might break on an empty database. + my $xml = $self->_request( + user => $self->{user}, + pass => $self->{pass}, + resultset => $self->{resultset}, + params => { + '-db' => $self->{db}, + '-lay' => $args{layout}, + '-max' => '1' + }, + query => '-findall' + ); + + return $xml; } diff --git a/lib/Net/FileMaker/XML/ResultSet.pm b/lib/Net/FileMaker/XML/ResultSet.pm index 58f2a01..1baa8b0 100644 --- a/lib/Net/FileMaker/XML/ResultSet.pm +++ b/lib/Net/FileMaker/XML/ResultSet.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::XML::ResultSet; +package + Net::FileMaker::XML::ResultSet; use strict; use warnings; @@ -19,19 +20,19 @@ Don't call this module directly, instead use L. sub new { - my($class, %args) = @_; - my @rows; - my $self = { - result_hash => $args{rs}, # complete result hash provided by Net::FileMaker::XML search methods - db => $args{db}, # ref to the db, it is useful to add an $row->update method later - fields_def => undef, # fields definition - rows => \@rows, # resultset's rows - next_index => 0, # index used by the "next" method - }; - bless $self , $class; - # let's begin the parsing - $self->_parse; - return $self; + my($class, %args) = @_; + my @rows; + my $self = { + result_hash => $args{rs}, # complete result hash provided by Net::FileMaker::XML search methods + db => $args{db}, # ref to the db, it is useful to add an $row->update method later + fields_def => undef, # fields definition + rows => \@rows, # resultset's rows + next_index => 0, # index used by the "next" method + }; + bless $self , $class; + # let's begin the parsing + $self->_parse; + return $self; } =head2 fields_definition @@ -43,8 +44,8 @@ L. sub fields_definition { - my $self = shift; - return $self->{fields_def}->fields; + my $self = shift; + return $self->{fields_def}->fields; } @@ -70,9 +71,10 @@ sub http_response =head2 datasource -Return an hash with useful information about the datasource. -You don't need to use this information to parse the date, time or timestamp fields -as it is already done by the C methods of each row returned by the I method. +Return an hash with useful information about the datasource. You don't need to +use this information to parse the date, time or timestamp fields as it is +already done by the C methods of each row returned by the I +method. the hash contains: @@ -80,31 +82,31 @@ the hash contains: =item * database - database file name + database file name =item * layout - kind of layout, eg. 'List + kind of layout, eg. 'List =item * timestamp-format - eg. 'MM/dd/yyyy HH:mm:ss' + eg. 'MM/dd/yyyy HH:mm:ss' =item * date-format - eg. 'MM/dd/yyyy' + eg. 'MM/dd/yyyy' =item * time-format - eg. 'HH:mm:ss' + eg. 'HH:mm:ss' =item * table - name of the selected database table + name of the selected database table =item * total-count - total count of the records in the selected table + total count of the records in the selected table =back @@ -113,8 +115,8 @@ the hash contains: sub datasource { - my $self = shift; - return $self->{result_hash}{datasource}; + my $self = shift; + return $self->{result_hash}{datasource}; } =head2 xmlns @@ -125,8 +127,8 @@ Returns the XML namespace of the response. sub xmlns { - my $self = shift; - return $self->{result_hash}{xmlns}; + my $self = shift; + return $self->{result_hash}{xmlns}; } @@ -138,8 +140,8 @@ Returns the XML version of the response. sub version { - my $self = shift; - return $self->{result_hash}{version}; + my $self = shift; + return $self->{result_hash}{version}; } =head2 product @@ -150,11 +152,11 @@ Returns an hash with information about the FileMaker Server. sub product { - my $self = shift; - return { - version => $self->{result_hash}{product}{'FileMaker Web Publishing Engine'}{version}, - build => $self->{result_hash}{product}{'FileMaker Web Publishing Engine'}{build}, - } + my $self = shift; + return { + version => $self->{result_hash}{product}{'FileMaker Web Publishing Engine'}{version}, + build => $self->{result_hash}{product}{'FileMaker Web Publishing Engine'}{build}, + } } =head2 total_count @@ -166,8 +168,8 @@ but B take into account the limit clause. sub total_count { - my $self = shift; - return $self->{result_hash}{resultset}{count}; + my $self = shift; + return $self->{result_hash}{resultset}{count}; } =head2 fetch_size @@ -179,8 +181,8 @@ does take into account the limit clause. sub fetch_size { - my $self = shift; - return $self->{result_hash}{resultset}{'fetch-size'}; + my $self = shift; + return $self->{result_hash}{resultset}{'fetch-size'}; } @@ -193,14 +195,15 @@ objects. sub rows { - my $self = shift; - return $self->{rows}; + my $self = shift; + return $self->{rows}; } =head2 next_row -Returns the next L if available, if not returns an undefined value +Returns the next L if available, if not +returns an undefined value. =cut @@ -208,11 +211,14 @@ sub next_row { my $self = shift; # if next row exists let's return it, otherwise undefined - if( $self->{next_index} < scalar @{$self->{rows}} ){ + if( $self->{next_index} < scalar @{$self->{rows}} ) + { my $index = $self->{next_index}; - $self->{next_index} ++ ; + $self->{next_index}++; return @{$self->{rows}}[$index]; - }else{ + } + else + { return; } } @@ -236,38 +242,48 @@ sub reset_index # calls all the methods that parse the single blocks of the response sub _parse { - my $self = shift; - # parse the resultset - $self->_parse_field_definition; - $self->_parse_rows; - return; + my $self = shift; + # parse the resultset + $self->_parse_field_definition; + $self->_parse_rows; + return; } # _parse_field_definition # parses the field definition instantiating a N::F::X::D::FieldDefinition sub _parse_field_definition { - my ($self) = @_; - require Net::FileMaker::XML::ResultSet::FieldsDefinition; - $self->{fields_def} = Net::FileMaker::XML::ResultSet::FieldsDefinition->new($self->{result_hash}{metadata}{'field-definition'}); - return; + my ($self) = @_; + require Net::FileMaker::XML::ResultSet::FieldsDefinition; + $self->{fields_def} = Net::FileMaker::XML::ResultSet::FieldsDefinition->new( + $self->{result_hash}{metadata}{'field-definition'} + ); + return; } # _parse_rows sub _parse_rows { - my $self = shift; - require Net::FileMaker::XML::ResultSet::Row; - my $cd = $self->fields_definition; # column definition, I need it for the inflater - my $ds = $self->datasource; - if($self->fetch_size == 1){ # if the fetch size is 1 it returns an hash with the row, if more it returns an array - push @{$self->{rows}} , Net::FileMaker::XML::ResultSet::Row->new($self->{result_hash}{resultset}{record},$self); - }else{ - for my $row (@{$self->{result_hash}{resultset}{record}}){ - push @{$self->{rows}} , Net::FileMaker::XML::ResultSet::Row->new($row,$self); - } - } - return; + my $self = shift; + require Net::FileMaker::XML::ResultSet::Row; + my $cd = $self->fields_definition; # column definition, I need it for the inflater + my $ds = $self->datasource; + + # If the fetch size is 1 it returns an hash with the row, if more it returns an array + if($self->fetch_size == 1) + { + push @{$self->{rows}} , Net::FileMaker::XML::ResultSet::Row->new( + $self->{result_hash}{resultset}{record},$self + ); + } + else + { + for my $row (@{$self->{result_hash}{resultset}{record}}) + { + push @{$self->{rows}} , Net::FileMaker::XML::ResultSet::Row->new($row,$self); + } + } + return; } 1; diff --git a/lib/Net/FileMaker/XML/ResultSet/FieldsDefinition.pm b/lib/Net/FileMaker/XML/ResultSet/FieldsDefinition.pm index cae8121..1ec2995 100644 --- a/lib/Net/FileMaker/XML/ResultSet/FieldsDefinition.pm +++ b/lib/Net/FileMaker/XML/ResultSet/FieldsDefinition.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::XML::ResultSet::FieldsDefinition; +package + Net::FileMaker::XML::ResultSet::FieldsDefinition; use strict; use warnings; @@ -19,14 +20,14 @@ directly, instead use L. sub new { - my($class, $res_hash) = @_; - - my $self = { - result_hash => $res_hash, # complete result hash provided by Net::FileMaker::XML search methods - }; - bless $self , $class; - $self->_parse; - return $self; + my($class, $res_hash) = @_; + + my $self = { + result_hash => $res_hash, # complete result hash provided by Net::FileMaker::XML search methods + }; + bless $self , $class; + $self->_parse; + return $self; } =head2 get($field_name) @@ -38,8 +39,8 @@ Returns the field definition object sub get { - my ( $self, $field ) = @_; - return $self->{fields}{$field}; + my ( $self, $field ) = @_; + return $self->{fields}{$field}; } =head2 fields @@ -51,8 +52,8 @@ Returns an hash with the field definition objects sub fields { - my ( $self, $field ) = @_; - return $self->{fields}; + my ( $self, $field ) = @_; + return $self->{fields}; } @@ -60,14 +61,14 @@ sub fields # sub _parse { - my $self = shift; - my %fields; - require Net::FileMaker::XML::ResultSet::FieldsDefinition::Field; - foreach my $key (sort keys %{$self->{result_hash}}) { - $fields{$key} = Net::FileMaker::XML::ResultSet::FieldsDefinition::Field->new($self->{result_hash}{$key}); - } - $self->{fields} = \%fields; - return; + my $self = shift; + my %fields; + require Net::FileMaker::XML::ResultSet::FieldsDefinition::Field; + foreach my $key (sort keys %{$self->{result_hash}}) { + $fields{$key} = Net::FileMaker::XML::ResultSet::FieldsDefinition::Field->new($self->{result_hash}{$key}); + } + $self->{fields} = \%fields; + return; } 1; diff --git a/lib/Net/FileMaker/XML/ResultSet/FieldsDefinition/Field.pm b/lib/Net/FileMaker/XML/ResultSet/FieldsDefinition/Field.pm index 5d3fb58..6834ccb 100644 --- a/lib/Net/FileMaker/XML/ResultSet/FieldsDefinition/Field.pm +++ b/lib/Net/FileMaker/XML/ResultSet/FieldsDefinition/Field.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::XML::ResultSet::FieldsDefinition::Field; +package + Net::FileMaker::XML::ResultSet::FieldsDefinition::Field; use strict; use warnings; @@ -20,14 +21,14 @@ instead use L. sub new { - my($class, $res_hash) = @_; - - my $self = { - result_hash => $res_hash - }; - bless $self , $class; - $self->_parse; - return $self; + my($class, $res_hash) = @_; + + my $self = { + result_hash => $res_hash + }; + bless $self , $class; + $self->_parse; + return $self; } =head2 get($field_name) @@ -38,37 +39,58 @@ It may return (possible results in parentheses): =over -=item * global (0,1) +=item + +* global (0,1) + +=item + +* numeric-only (0,1) + +=item + +* four-digit-year (0,1) + +=item -=item * numeric-only (0,1) +* not-empty (0,1) -=item * four-digit-year (0,1) +=item -=item * not-empty (0,1) +* auto_enter (0,1) -=item * auto_enter (0,1) +=item -=item * type (“normal”, “calculation”, or “summary”) +* type ("normal", "calculation", or "summary") -=item * time-of_day (0,1) +=item -=item * max-repeat (int) +* time-of_day (0,1) -=item * max-characters (int) +=item -=item * result (“text”, “number”, “date”, “time”, “timestamp”, or “container”) +* max-repeat (int) + +=item + +* max-characters (int) + +=item + +* result ("text", "number", "date", "time", "timestamp", or "container") =back + =cut my @availables = qw( global numeric-only four-digit-year not-empty auto-enter type time-of-day max-repeat max-characters result ); sub get { - my ( $self, $par ) = @_; - croak 'this parameter is not defined!' if(! grep { $_ eq $par } @availables); - return $self->{$par}; + my ( $self, $par ) = @_; + croak 'this parameter is not defined!' if(! grep { $_ eq $par } @availables); + return $self->{$par}; } =head2 get_all @@ -79,9 +101,9 @@ Returns a reference to an hash with all the parameters of this field. sub get_all { - my $self = shift; - my %tmp = map { $_ => $self->{$_} } @availables; - return \%tmp; + my $self = shift; + my %tmp = map { $_ => $self->{$_} } @availables; + return \%tmp; } @@ -89,18 +111,18 @@ sub get_all # sub _parse { - my $self = shift; - - # boolean fields ( "yes" or "no" ) to be converted into 1 or 0 - my @bools = qw( global numeric-only four-digit-year not-empty auto-enter time-of-day ); - foreach my $key (keys %{$self->{result_hash}}) { - if(grep {$_ eq $key} @bools){ - $self->{$key} = $self->{result_hash}{$key} eq 'no' ? 0 : 1; - }else{ - $self->{$key} = $self->{result_hash}{$key}; - } - } - return; + my $self = shift; + + # boolean fields ( "yes" or "no" ) to be converted into 1 or 0 + my @bools = qw( global numeric-only four-digit-year not-empty auto-enter time-of-day ); + foreach my $key (keys %{$self->{result_hash}}) { + if(grep {$_ eq $key} @bools){ + $self->{$key} = $self->{result_hash}{$key} eq 'no' ? 0 : 1; + }else{ + $self->{$key} = $self->{result_hash}{$key}; + } + } + return; } 1; diff --git a/lib/Net/FileMaker/XML/ResultSet/Row.pm b/lib/Net/FileMaker/XML/ResultSet/Row.pm index 0c80fa4..ca3bdc8 100644 --- a/lib/Net/FileMaker/XML/ResultSet/Row.pm +++ b/lib/Net/FileMaker/XML/ResultSet/Row.pm @@ -1,4 +1,5 @@ -package Net::FileMaker::XML::ResultSet::Row; +package + Net::FileMaker::XML::ResultSet::Row; use strict; use warnings; @@ -22,20 +23,20 @@ instead use L. sub new { - my($class, $res_hash , $dataset) = @_; - - my $cd = $dataset->fields_definition; # column definition, I need it for the inflater - my $ds = $dataset->datasource; - my $db = $dataset->{db}; - - my $self = { - columns_def => $cd, - datasource => $ds, - result_hash => $res_hash, - db_ref => $db - }; - bless $self , $class; - return $self; + my($class, $res_hash , $dataset) = @_; + + my $cd = $dataset->fields_definition; # column definition, I need it for the inflater + my $ds = $dataset->datasource; + my $db = $dataset->{db}; + + my $self = { + columns_def => $cd, + datasource => $ds, + result_hash => $res_hash, + db_ref => $db + }; + bless $self , $class; + return $self; } =head2 mod_id @@ -46,8 +47,8 @@ Returns the mod id for this row. sub mod_id { - my $self = shift; - return $self->{result_hash}{'mod-id'}; + my $self = shift; + return $self->{result_hash}{'mod-id'}; } @@ -59,8 +60,8 @@ Returns the record id for this row. sub record_id { - my $self = shift; - return $self->{result_hash}{'record-id'}; + my $self = shift; + return $self->{result_hash}{'record-id'}; } @@ -72,8 +73,8 @@ Returns the value of the selected column for this row. sub get { - my ( $self , $col ) = @_; - return $self->{result_hash}{field}{$col}{data}; + my ( $self , $col ) = @_; + return $self->{result_hash}{field}{$col}{data}; } =head2 get_type('colname') @@ -84,8 +85,8 @@ Returns the type of the selected column for this row. sub get_type { - my ( $self , $col ) = @_; - return $self->{columns_def}{$col}{result}; + my ( $self , $col ) = @_; + return $self->{columns_def}{$col}{result}; } =head2 get_max_length('colname') @@ -109,20 +110,20 @@ date, time or datetime returns, it will return a L object. sub get_inflated { - my ( $self , $col ) = @_; - # if the field is a “date”, “time” or “timestamp" - if(defined $self->get_type($col)){ - if($self->get_type($col) =~ m/^(date|time|timestamp)$/xms ){ - # let's convert it to a DateTime - my $pattern = $self->{datasource}{"$1-format"}; # eg. 'MM/dd/yyyy HH:mm:ss' - my $cldr = DateTime::Format::CLDR->new( - pattern => $pattern - ); - return $cldr->parse_datetime($self->{result_hash}{field}{$col}{data}) if(defined $self->{result_hash}{field}{$col}{data}); - } - } - # if the type is one of the ones above let's convert the value in a DateTime - return $self->{result_hash}{field}{$col}{data}; + my ( $self , $col ) = @_; + # if the field is a “date”, “time” or “timestamp" + if(defined $self->get_type($col)){ + if($self->get_type($col) =~ m/^(date|time|timestamp)$/xms ){ + # let's convert it to a DateTime + my $pattern = $self->{datasource}{"$1-format"}; # eg. 'MM/dd/yyyy HH:mm:ss' + my $cldr = DateTime::Format::CLDR->new( + pattern => $pattern + ); + return $cldr->parse_datetime($self->{result_hash}{field}{$col}{data}) if(defined $self->{result_hash}{field}{$col}{data}); + } + } + # if the type is one of the ones above let's convert the value in a DateTime + return $self->{result_hash}{field}{$col}{data}; } =head2 get_columns @@ -132,12 +133,12 @@ Returns an hash with column names & relative values for this row. =cut sub get_columns { - my ( $self , $col ) = @_; - my %res; - foreach my $k(sort keys %{$self->{result_hash}{field}}) { - $res{$k} = $self->get($k); - } - return \%res; + my ( $self , $col ) = @_; + my %res; + foreach my $k(sort keys %{$self->{result_hash}{field}}) { + $res{$k} = $self->get($k); + } + return \%res; } =head2 get_inflated_columns @@ -149,12 +150,12 @@ If the type is date, time or datetime returns a L object. sub get_inflated_columns { - my ( $self , $col ) = @_; - my %res; - foreach my $k(sort keys %{$self->{result_hash}{field}}) { - $res{$k} = $self->get_inflated($k); - } - return \%res; + my ( $self , $col ) = @_; + my %res; + foreach my $k(sort keys %{$self->{result_hash}{field}}) { + $res{$k} = $self->get_inflated($k); + } + return \%res; } =head2 update(params => { 'Field Name' => $value , ... }) @@ -192,43 +193,43 @@ $rs->update(params => { 'Field Name[1]' => 'hello' , 'Field Name[3]' => 'world' sub update { - my ( $self , %pars ) = @_; - my $db = $self->{db_ref}; - my $layout = $self->{datasource}{layout}; - - # let's play with DateTimes and arrays if passed - foreach my $key (keys %{$pars{params}}){ - my $value = $pars{params}{$key}; - - # if the type is datetime let's format it right - $pars{params}{$key} = $self->_get_formatted_dt($key,$value) if(ref($value) eq 'DateTime' ); - - # let's transform the array into the single params, taking into account the datetimes - if(ref($value) eq 'ARRAY'){ - - # fm's arrays have a predefined number of slots - # throw error if the array is longer than the max size for this field - croak 'the lenght of the array exceeds the max size of the field' if( scalar @$value > $self->get_max_length($key) ); - + my ( $self , %pars ) = @_; + my $db = $self->{db_ref}; + my $layout = $self->{datasource}{layout}; + + # let's play with DateTimes and arrays if passed + foreach my $key (keys %{$pars{params}}){ + my $value = $pars{params}{$key}; + + # if the type is datetime let's format it right + $pars{params}{$key} = $self->_get_formatted_dt($key,$value) if(ref($value) eq 'DateTime' ); + + # let's transform the array into the single params, taking into account the datetimes + if(ref($value) eq 'ARRAY'){ + + # fm's arrays have a predefined number of slots + # throw error if the array is longer than the max size for this field + croak 'the lenght of the array exceeds the max size of the field' if( scalar @$value > $self->get_max_length($key) ); + for(my $i = 0; $i < scalar @$value; $i++) { - # if the user hasn't defined the value of an index it means he doesn't want it to be modified - if(defined $value->[$i]){ - - # manage datetimes - $value->[$i] = $self->_get_formatted_dt($key,$value) if(ref($value) eq 'DateTime' ); - - # set the param for the request - $pars{params}{$key."[".($i+1)."]"} = $value->[$i]; - - } + # if the user hasn't defined the value of an index it means he doesn't want it to be modified + if(defined $value->[$i]){ + + # manage datetimes + $value->[$i] = $self->_get_formatted_dt($key,$value) if(ref($value) eq 'DateTime' ); + + # set the param for the request + $pars{params}{$key."[".($i+1)."]"} = $value->[$i]; + + } } #finally let's delete the array from the params delete $pars{params}{$key}; - } - } - my $result = $db->edit(layout =>$layout , recid => $self->record_id , params => $pars{params} ); - return $result; + } + } + my $result = $db->edit(layout =>$layout , recid => $self->record_id , params => $pars{params} ); + return $result; } # _get_formatted_dt @@ -236,13 +237,13 @@ sub update sub _get_formatted_dt { - my ( $self , $fieldname , $dt ) = @_; + my ( $self , $fieldname , $dt ) = @_; # let's find what kind of field it is my $format = $self->get_type($fieldname); # and then it's format my $pattern = $self->{datasource}{"$format-format"}; # eg. 'MM/dd/yyyy HH:mm:ss' - my $result = DateTime::Format::CLDR->new(pattern => $pattern)->format_datetime($dt); - return $result; + my $result = DateTime::Format::CLDR->new(pattern => $pattern)->format_datetime($dt); + return $result; } =head2 remove(params => { 'Field Name' => $value , ... }) @@ -254,11 +255,11 @@ Deletes this row, returns an L object. sub remove { - my ( $self , %params ) = @_; - my $db = $self->{db_ref}; - my $layout = $self->{datasource}{layout}; - my $result = $db->delete(layout =>$layout , recid => $self->record_id , params => $params{params}); - return $result; + my ( $self , %params ) = @_; + my $db = $self->{db_ref}; + my $layout = $self->{datasource}{layout}; + my $result = $db->delete(layout =>$layout , recid => $self->record_id , params => $params{params}); + return $result; } diff --git a/t/00_load/00-net-filemaker.t b/t/00_load/00-net-filemaker.t index 6ab4618..a2d714c 100644 --- a/t/00_load/00-net-filemaker.t +++ b/t/00_load/00-net-filemaker.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; diff --git a/t/00_load/01-perlcritic.t b/t/00_load/01-perlcritic.t old mode 100755 new mode 100644 index bfc8eea..5d4108b --- a/t/00_load/01-perlcritic.t +++ b/t/00_load/01-perlcritic.t @@ -1,10 +1,9 @@ -#!perl -wT - use strict; use warnings; use Test::More; +plan skip_all => 'Perl::Critic false flagging issues with package declarations, skipping...'; eval 'use Test::Perl::Critic'; if ( $@ ) { diff --git a/t/00_load/02-pod.t b/t/00_load/02-pod.t old mode 100755 new mode 100644 index 1c4b79f..ec7bd88 --- a/t/00_load/02-pod.t +++ b/t/00_load/02-pod.t @@ -1,5 +1,3 @@ -#!perl -wT - use strict; use warnings; diff --git a/t/01_xml/00-load.t b/t/01_xml/00-load.t index fd76707..460ef4f 100644 --- a/t/01_xml/00-load.t +++ b/t/01_xml/00-load.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -19,4 +17,3 @@ BEGIN use_ok('Net::FileMaker::XML::Database'); } -diag( "Testing Net::FileMaker::XML $Net::FileMaker::XML::VERSION, Perl $], $^X" ); diff --git a/t/01_xml/01-dbnames.t b/t/01_xml/01-dbnames.t index 2fd8341..98f218a 100644 --- a/t/01_xml/01-dbnames.t +++ b/t/01_xml/01-dbnames.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; diff --git a/t/01_xml/02-layoutnames.t b/t/01_xml/02-layoutnames.t index 025e9e5..bda54f9 100644 --- a/t/01_xml/02-layoutnames.t +++ b/t/01_xml/02-layoutnames.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; diff --git a/t/01_xml/03-scriptnames.t b/t/01_xml/03-scriptnames.t index 9bf3c40..00d17ca 100644 --- a/t/01_xml/03-scriptnames.t +++ b/t/01_xml/03-scriptnames.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; diff --git a/t/01_xml/04-findall.t b/t/01_xml/04-findall.t index a2c18f3..33de429 100644 --- a/t/01_xml/04-findall.t +++ b/t/01_xml/04-findall.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; diff --git a/t/01_xml/05-findany.t b/t/01_xml/05-findany.t index 02f7db7..127f81d 100644 --- a/t/01_xml/05-findany.t +++ b/t/01_xml/05-findany.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; diff --git a/t/02_error/00-load.t b/t/02_error/00-load.t index c0df234..08b5f15 100644 --- a/t/02_error/00-load.t +++ b/t/02_error/00-load.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -10,4 +8,3 @@ BEGIN use_ok( 'Net::FileMaker::Error' ); } -diag( "Testing Net::FileMaker::Error, Perl $], $^X" ); diff --git a/t/02_error/01-en.t b/t/02_error/01-en.t index 119547e..d7ef166 100644 --- a/t/02_error/01-en.t +++ b/t/02_error/01-en.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -8,7 +6,7 @@ use Test::More tests => 7; use_ok('Net::FileMaker::Error'); # -# XML Errors +# XML Errors # my $xml = Net::FileMaker::Error->new(lang => 'en', type => 'xml'); ok($xml, 'Net::FileMaker::Error loaded XML strings in English'); @@ -20,7 +18,7 @@ my $xml_error_minusone = $xml->get_string('-1'); is($xml_error_minusone, 'Unknown error', 'Returned error string on -1'); # -# XSLT Errors +# XSLT Errors # my $xslt = Net::FileMaker::Error->new(lang => 'en', type => 'xslt'); ok($xslt, 'Net::FileMaker::Error loaded XSLT strings in English'); diff --git a/t/02_error/02-ja.t b/t/02_error/02-ja.t index 901e282..eb6f374 100644 --- a/t/02_error/02-ja.t +++ b/t/02_error/02-ja.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -8,7 +6,7 @@ use Test::More tests => 7; use_ok('Net::FileMaker::Error'); # -# XML Errors +# XML Errors # my $xml = Net::FileMaker::Error->new(lang => 'ja', type => 'xml'); ok($xml, 'Net::FileMaker::Error loaded XML strings in Japanese'); @@ -20,7 +18,7 @@ my $xml_error_minusone = $xml->get_string('-1'); is($xml_error_minusone, '原因不明のエラー', 'Returned error string on -1'); # -# XSLT Errors +# XSLT Errors # my $xslt = Net::FileMaker::Error->new(lang => 'ja', type => 'xslt'); ok($xslt, 'Net::FileMaker::Error loaded XSLT strings in Japanese'); diff --git a/t/02_error/03-it.t b/t/02_error/03-it.t index e475823..1a7e937 100644 --- a/t/02_error/03-it.t +++ b/t/02_error/03-it.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -8,7 +6,7 @@ use Test::More tests => 7; use_ok('Net::FileMaker::Error'); # -# XML Errors +# XML Errors # my $xml = Net::FileMaker::Error->new(lang => 'it', type => 'xml'); ok($xml, 'Net::FileMaker::Error loaded XML strings in Italian'); @@ -20,7 +18,7 @@ my $xml_error_minusone = $xml->get_string('-1'); is($xml_error_minusone, 'Errore sconosciuto', 'Returned error string on -1'); # -# XSLT Errors +# XSLT Errors # my $xslt = Net::FileMaker::Error->new(lang => 'it', type => 'xslt'); ok($xslt, 'Net::FileMaker::Error loaded XSLT strings in Italian'); diff --git a/t/03_resultset/00-load.t b/t/03_resultset/00-load.t index eff6f8d..17b0dc0 100644 --- a/t/03_resultset/00-load.t +++ b/t/03_resultset/00-load.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -10,4 +8,3 @@ BEGIN use_ok( 'Net::FileMaker::XML::ResultSet' ); } -diag( "Testing Net::FileMaker::XML::ResultSet, Perl $], $^X" ); diff --git a/t/03_resultset/01-instantiation.t b/t/03_resultset/01-instantiation.t index 49cb0e8..7f31a3e 100644 --- a/t/03_resultset/01-instantiation.t +++ b/t/03_resultset/01-instantiation.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -26,8 +24,8 @@ ok($fmdb,'Logged in'); my $layouts = $fmdb->layoutnames; if(ref($layouts) eq 'ARRAY') { - my $records = $fmdb->findall(layout => $layouts->[0], params => { '-max' => 1}); - ok($records, 'Directly constructed Net::FileMaker::XML::ResultSet'); + my $records = $fmdb->findall(layout => $layouts->[0], params => { '-max' => 1}); + ok($records, 'Directly constructed Net::FileMaker::XML::ResultSet'); } done_testing(); diff --git a/t/03_resultset/02-rows.t b/t/03_resultset/02-rows.t index 4e3e6dd..cfb8a23 100644 --- a/t/03_resultset/02-rows.t +++ b/t/03_resultset/02-rows.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -26,8 +24,8 @@ ok($fmdb,'Logged in'); my $layouts = $fmdb->layoutnames; if(ref($layouts) eq 'ARRAY') { - my $records = $fmdb->findall(layout => $layouts->[0], params => { '-max' => 1})->rows; - is(ref(@$records[0]), 'Net::FileMaker::XML::ResultSet::Row', 'the first row of the RS is a Net::FileMaker::XML::ResultSet::Row'); + my $records = $fmdb->findall(layout => $layouts->[0], params => { '-max' => 1})->rows; + is(ref(@$records[0]), 'Net::FileMaker::XML::ResultSet::Row', 'the first row of the RS is a Net::FileMaker::XML::ResultSet::Row'); } done_testing(); diff --git a/t/04_field_definition/00-load.t b/t/04_field_definition/00-load.t index a78c1ed..905193d 100644 --- a/t/04_field_definition/00-load.t +++ b/t/04_field_definition/00-load.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -10,4 +8,3 @@ BEGIN use_ok( 'Net::FileMaker::XML::ResultSet::FieldsDefinition' ); } -diag( "Testing Net::FileMaker::XML::ResultSet::FieldsDefinition, Perl $], $^X" ); diff --git a/t/04_field_definition/01-fields.t b/t/04_field_definition/01-fields.t index 009ce72..bc6d110 100644 --- a/t/04_field_definition/01-fields.t +++ b/t/04_field_definition/01-fields.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -27,7 +25,7 @@ my $layouts = $fmdb->layoutnames; if(ref($layouts) eq 'ARRAY') { my $records = $fmdb->findall(layout => $layouts->[0], params => { '-max' => 2}); - is(ref($records->fields_definition), 'HASH', 'the fields method returns an Hash'); + is(ref($records->fields_definition), 'HASH', 'the fields method returns an Hash'); } done_testing(); diff --git a/t/05_row/00-load.t b/t/05_row/00-load.t index ea8b2cc..21f1cb0 100644 --- a/t/05_row/00-load.t +++ b/t/05_row/00-load.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -10,4 +8,3 @@ BEGIN use_ok( 'Net::FileMaker::XML::ResultSet::Row' ); } -diag( "Net::FileMaker::XML::ResultSet::Row, Perl $], $^X" ); diff --git a/t/05_row/01-inflated.t b/t/05_row/01-inflated.t index 2d04943..82c8374 100644 --- a/t/05_row/01-inflated.t +++ b/t/05_row/01-inflated.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; @@ -30,13 +28,13 @@ if(ref($layouts) eq 'ARRAY') my $records = $fmdb->findall(layout => $layouts->[0], params => { '-max' => 2})->rows; for my $row (@$records){ - my $fields = $row->get_inflated_columns; + my $fields = $row->get_inflated_columns; foreach my $key (keys %$fields) { - my $col = $fields->{$key}; - if(defined $col){ - $success = 0 if(ref $col !~ m/^(ARRAY|SCALAR|DateTime)$/xms); - } - } + my $col = $fields->{$key}; + if(defined $col){ + $success = 0 if(ref $col !~ m/^(ARRAY|SCALAR|DateTime)$/xms); + } + } } } diff --git a/t/manifest.t b/t/manifest.t index 45eb83f..479b21f 100644 --- a/t/manifest.t +++ b/t/manifest.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; use Test::More; diff --git a/t/pod.t b/t/pod.t index ee8b18a..056e192 100644 --- a/t/pod.t +++ b/t/pod.t @@ -1,5 +1,3 @@ -#!perl -T - use strict; use warnings; use Test::More;