3 MODULE = Mouse PACKAGE = Mouse::Util
8 is_class_loaded(SV* sv = &PL_sv_undef)
11 get_code_info(CV* code)
16 if((gv = CvGV(code)) && isGV(gv) && (stash = GvSTASH(gv))){
18 mPUSHs(newSVpvn_share(HvNAME_get(stash), HvNAMELEN_get(stash), 0U));
19 mPUSHs(newSVpvn_share(GvNAME_get(gv), GvNAMELEN_get(gv), 0U));
23 get_code_package(CV* code)
27 if(CvGV(code) && isGV(CvGV(code)) && (stash = GvSTASH(CvGV(code)))){
28 RETVAL = newSVpvn_share(HvNAME_get(stash), HvNAMELEN_get(stash), 0U);
36 MODULE = Mouse PACKAGE = Mouse::Meta::Module
39 INSTALL_SIMPLE_READER_WITH_KEY(Module, name, package);
40 INSTALL_SIMPLE_READER_WITH_KEY(Module, _method_map, methods);
41 INSTALL_SIMPLE_READER_WITH_KEY(Module, _attribute_map, attributes);
43 MODULE = Mouse PACKAGE = Mouse::Meta::Class
46 INSTALL_SIMPLE_READER(Class, roles);
47 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Class, is_anon_class, anon_serial_id);
49 MODULE = Mouse PACKAGE = Mouse::Meta::Role
52 INSTALL_SIMPLE_READER_WITH_KEY(Role, get_roles, roles);
53 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Role, is_anon_role, anon_serial_id);
56 MODULE = Mouse PACKAGE = Mouse::Meta::Attribute
60 INSTALL_SIMPLE_READER(Attribute, name);
61 INSTALL_SIMPLE_READER(Attribute, associated_class);
62 INSTALL_SIMPLE_READER(Attribute, accessor);
63 INSTALL_SIMPLE_READER(Attribute, reader);
64 INSTALL_SIMPLE_READER(Attribute, writer);
65 INSTALL_SIMPLE_READER(Attribute, predicate);
66 INSTALL_SIMPLE_READER(Attribute, clearer);
67 INSTALL_SIMPLE_READER(Attribute, handles);
69 INSTALL_SIMPLE_READER_WITH_KEY(Attribute, _is_metadata, is);
70 INSTALL_SIMPLE_READER_WITH_KEY(Attribute, is_required, required);
71 INSTALL_SIMPLE_READER(Attribute, default);
72 INSTALL_SIMPLE_READER_WITH_KEY(Attribute, is_lazy, lazy);
73 INSTALL_SIMPLE_READER_WITH_KEY(Attribute, is_lazy_build, lazy_build);
74 INSTALL_SIMPLE_READER_WITH_KEY(Attribute, is_weak_ref, weak_ref);
75 INSTALL_SIMPLE_READER(Attribute, init_arg);
76 INSTALL_SIMPLE_READER(Attribute, type_constraint);
77 INSTALL_SIMPLE_READER(Attribute, trigger);
78 INSTALL_SIMPLE_READER(Attribute, builder);
79 INSTALL_SIMPLE_READER_WITH_KEY(Attribute, should_auto_deref, auto_deref);
80 INSTALL_SIMPLE_READER_WITH_KEY(Attribute, should_coerce, coerce);
81 INSTALL_SIMPLE_READER(Attribute, documentation);
84 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_accessor, accessor);
85 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_reader, reader);
86 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_writer, writer);
87 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_predicate, predicate);
88 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_clearer, clearer);
89 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_handles, handles);
91 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_default, default);
92 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_type_constraint, type_constraint);
93 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_trigger, trigger);
94 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_builder, builder);
95 INSTALL_SIMPLE_PREDICATE_WITH_KEY(Attribute, has_documentation, documentation);
97 MODULE = Mouse PACKAGE = Mouse::Meta::TypeConstraint
100 INSTALL_SIMPLE_READER(TypeConstraint, name);
101 INSTALL_SIMPLE_READER(TypeConstraint, parent);
102 INSTALL_SIMPLE_READER(TypeConstraint, message);
104 INSTALL_SIMPLE_READER_WITH_KEY(TypeConstraint, _compiled_type_constraint, compiled_type_constraint);
105 INSTALL_SIMPLE_READER(TypeConstraint, _compiled_type_coercion); /* Mouse specific */
107 INSTALL_SIMPLE_PREDICATE_WITH_KEY(TypeConstraint, has_coercion, _compiled_type_coercion);