-
-
17 Jan 2012 00:51:18 UTC
- Distribution: JSPL
- Source (raw)
- Browse (raw)
- Changes
- How to Contribute
- Issues (7)
- Testers (0 / 22 / 0)
- Kwalitee
Bus factor: 0- % Coverage
- License: perl_5
- Activity
24 month- Tools
- Download (116.87KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
- Dependencies
- Test::Exception
- Test::More
- and possibly others
- Reverse dependencies
- CPAN Testers List
- Dependency graph
NAME
JSPL::Runtime - Runs contexts
SYNOPSIS
use JSPL; my $rt = JSPL::Runtime->new(); my $ctx = $rt->create_context(); # BTW, if you don't need the runtime, it is always easier to just: use JSPL; my $ctx = JSPL->stock_context();
DESCRIPTION
In SpiderMonkey, a runtime is the data structure that holds javascript variables, objects, script and contexts. Every application needs to have a runtime. This class encapsulates the SpiderMonkey runtime object.
The main use of a runtime in JSPL is to create contexts, i.e. JSPL::Context instances.
INTERFACE
CLASS METHODS
- new ( [ $maxbytes] )
-
Creates a new
JSPL::Runtime
object and returns it.If the $maxbytes option is given, it's taken to be the number of bytes that can be allocated before garbage collection is run. If omitted defaults to 4MB.
INSTANCE METHODS
PACKAGE VARIABLES
- $MAXBYTES
-
The default max number of bytes that can be allocated before garbage collection is run. Used when you don't pass a $maxbytes parameter to "new".
Useful to set the default before you call "stock_context" in JSPL.
Module Install Instructions
To install JSPL, copy and paste the appropriate command in to your terminal.
cpanm JSPL
perl -MCPAN -e shell install JSPL
For more information on module installation, please visit the detailed CPAN module installation guide.