Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
Jifty::Bootstrap(3)   User Contributed Perl Documentation  Jifty::Bootstrap(3)

NAME
       Jifty::Bootstrap	- Insert initial data into your	database

DESCRIPTION
       "Jifty::Bootstrap" is an	abstract base class for	your application's
       bootstrapping.  Use it to set up	initial	data in	your database when
       your application	is first installed.

EXAMPLE
	package	MyApp::Bootstrap;
	use base 'Jifty::Bootstrap';

	sub run	{
	    my $user = MyApp::CurrentUser->new(	_bootstrap => 1);
	    my $modelclass = MyApp::Model::Thingy->new(current_user => $user);
	    $modelclass->create( name => 'Widget');
	};

   run
       "run" is	the workhorse method for the Bootstrap class.  This takes care
       of setting up internal data structures and initializing things in an
       application-dependent manner.

SEE ALSO
       Jifty::Upgrade, Jifty::Script::Schema

LICENSE
       Jifty is	Copyright 2005-2010 Best Practical Solutions, LLC.  Jifty is
       distributed under the same terms	as Perl	itself.

perl v5.32.1			  2013-01-29		   Jifty::Bootstrap(3)

NAME | DESCRIPTION | EXAMPLE | SEE ALSO | LICENSE

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=Jifty::Bootstrap&sektion=3&manpath=FreeBSD+13.1-RELEASE+and+Ports>

home | help