provide a trail of links towards the arguments passable to OR->connect
Christian Walde [Mon, 12 Sep 2016 16:02:12 +0000 (18:02 +0200)]
lib/Object/Remote.pm
lib/Object/Remote/Connection.pm
lib/Object/Remote/Connector/INET.pm
lib/Object/Remote/Connector/Local.pm
lib/Object/Remote/Connector/LocalSudo.pm
lib/Object/Remote/Connector/SSH.pm
lib/Object/Remote/Connector/STDIO.pm
lib/Object/Remote/Connector/UNIX.pm
lib/Object/Remote/Role/Connector.pm
lib/Object/Remote/Role/Connector/PerlInterpreter.pm

index c2324df..bcace31 100644 (file)
@@ -112,6 +112,11 @@ to block until an asynchronous call completes or fails.
 
   my $conn = Object::Remote->connect('root@'); # connection over sudo
 
+  my $conn = Object::Remote->connect('root@', %args); # can take optional args
+
+Convenience method for calling L<Object::Remote::Connection/new_from_spec> in a
+L<Future>-compatible way.
+
 =head2 new::on
 
   my $eval = Eval::WithLexicals->new::on($conn);
index bb1b260..d4dee82 100644 (file)
@@ -528,6 +528,19 @@ Object::Remote::Connection - An underlying connection for L<Object::Remote>
 
 This is the class that supports connections to remote objects.
 
+=head1 METHODS
+
+=head2 new_from_spec
+
+  my $conn = Object::Remote::Connection->new_from_spec($spec, %args);
+
+Not intended for direct use, called by L<Object::Remote/connect> in a
+L<Future>-compatible way.
+
+Uses the spec to guess the appropiate Object::Remote::Connector::* class to use,
+instantiates it with the spec and any further arguments given, then calls
+C<connect> on it in a L<Future>-compatible way.
+
 =head1 SEE ALSO
 
 =over 4
index eb0f188..09fb583 100644 (file)
@@ -28,3 +28,16 @@ push @Object::Remote::Connection::Guess, sub {
 };
 
 1;
+
+=head1 NAME
+
+Object::Remote::Connector::INET - A connector for INET sockets
+
+=head1 ARGUMENTS
+
+Inherits arguments from L<Object::Remote::Role::Connector> and provides the
+following:
+
+=head2 socket_path
+
+=cut
index 6119e3f..6dfd9ab 100644 (file)
@@ -16,3 +16,14 @@ push @Object::Remote::Connection::Guess, sub {
 };
 
 1;
+
+=head1 NAME
+
+Object::Remote::Connector::Local - A connector for a local Perl process
+
+=head1 ARGUMENTS
+
+Inherits arguments from L<Object::Remote::Role::Connector::PerlInterpreter> and
+provides no own arguments.
+
+=cut
index f3db7ea..886f5fe 100644 (file)
@@ -97,3 +97,21 @@ push @Object::Remote::Connection::Guess, sub {
 };
 
 1;
+
+=head1 NAME
+
+Object::Remote::Connector::LocalSudo - A connector for a local Perl process with
+sudo
+
+=head1 ARGUMENTS
+
+Inherits arguments from L<Object::Remote::Connector::Local> and provides the
+following:
+
+=head2 target_user
+
+=head2 password_callback
+
+=head2 sudo_perl_command
+
+=cut
index 73bc2fc..ea27a37 100644 (file)
@@ -42,3 +42,22 @@ push @Object::Remote::Connection::Guess, sub {
 };
 
 1;
+
+=head1 NAME
+
+Object::Remote::Connector::SSH - A connector for SSH servers
+
+=head1 ARGUMENTS
+
+Inherits arguments from L<Object::Remote::Role::Connector::PerlInterpreter> and
+provides the following:
+
+=head2 ssh_to
+
+=head2 ssh_perl_command
+
+=head2 ssh_options
+
+=head2 ssh_command
+
+=cut
index 69ba95d..908f8b3 100644 (file)
@@ -24,3 +24,13 @@ sub connect {
 }
 
 1;
+
+=head1 NAME
+
+Object::Remote::Connector::STDIO - ???
+
+=head1 ARGUMENTS
+
+Provides no arguments.
+
+=cut
index 99e9a44..ca90dda 100644 (file)
@@ -28,3 +28,16 @@ push @Object::Remote::Connection::Guess, sub {
 };
 
 1;
+
+=head1 NAME
+
+Object::Remote::Connector::UNIX - A connector for UNIX sockets
+
+=head1 ARGUMENTS
+
+Inherits arguments from L<Object::Remote::Role::Connector> and provides the
+following:
+
+=head2 socket_path
+
+=cut
index 8ad06c2..4386a82 100644 (file)
@@ -62,3 +62,13 @@ sub connect {
 }
 
 1;
+
+=head1 NAME
+
+Object::Remote::Role::Connector - Basic Future-compatible connector capability
+
+=head1 ARGUMENTS
+
+=head2 timeout
+
+=cut
index 6a3093b..7dcbc6a 100644 (file)
@@ -288,6 +288,9 @@ and is configurable via arguments passed to the constructor.
 
 =head1 ARGUMENTS
 
+Inherits arguments from L<Object::Remote::Role::Connector> and provides the
+following:
+
 =over 4
 
 =item perl_command