Manpage logo

SPVM::Builder::ScriptInfo - Script Information

Name  Description  Usage  Class Methods  new  Instance Methods  get_class_names  has_config_file  is_resource_loader  get_config_file  get_config_content  get_config  Copyright & License 

Name

SPVM::Builder::ScriptInfo − Script Information

Description

The SPVM::Builder::ScriptInfo class has methods to manipulate SPVM script information.

Usage

my $config_info = SPVM::Builder::ScriptInfo−>new(class_name => "Foo");

Class Methods

new

my $config_info = SPVM::Builder::ScriptInfo−>new(%options);

Creates an SPVM::Builder::ScriptInfo object given options %options, and returns it.

The class specified by "class_name" option or "script_name" option is compiled and the runtime is generated.

"class_name" option or "script_name" option must be defined.

Options:

"class_name"

A class name.

"script_name"

A script name.

Exceptions:

The "class_name" option or the "script_name" option must be defined. Otherwise, an exception is thrown.

Instance Methods

get_class_names

my $class_names = $config_info−>get_class_names;

Returns the names of all classes, interfaces, and multi−numeric types except for anon classes and anon classes generated by anon methods.

has_config_file

my $has_config_file = $config_info−>has_config_file($class_name);

If the class given by the class name has a config file, returns 1, otherwise returns 0.

Exceptions:

The class name $class_name must be defined. Otherwise, an exception is thrown.

is_resource_loader

my $is_resource_loader = $config_info−>is_resource_loader($class_name);

If the class given by the class name $class_name is a class that load resources, returns 1, otherwise returns 0.

Exceptions:

The class name $class_name must be defined. Otherwise, an exception is thrown.

get_config_file

my $config_file = $config_info−>get_config_file($class_name);

Returns the file path of the config for the class given by the class name $class_name.

Exceptions:

The class name $class_name must be defined. Otherwise, an exception is thrown.

The config file for the class "%s" is not found. Otherwise, an exception is thrown.

get_config_content

my $config_content = $config_info−>get_config_content($class_name);

Returns the content of the config for the class given by the class name $class_name.

Exceptions:

Exceptions thrown by "get_config_file" method could be thrown.

get_config

my $config = $config_info−>get_config($class_name);

Returns a config object for the class given by the class name $class_name.

Exceptions:

Exceptions thrown by "get_config_file" method could be thrown.

Copyright & License

Copyright (c) 2023 Yuki Kimoto

MIT License


Updated 2026-06-01 - jenkler.se | uex.se