[pve-devel] [PATCH pve-common v1 22/23] sectionconfig: note that `createSchema()` is universal for all plugins
Max R. Carrara
m.carrara at proxmox.com
Fri Dec 19 20:44:57 CET 2025
... in the docstring of the `createSchema()` method, mostly because
this might not be super obvious for readers not as familiar with
PVE::SectionConfig.
Adapt the header to reflect this.
While at it, also use an L<> tag for PVE::JSONSchema.
Signed-off-by: Max R. Carrara <m.carrara at proxmox.com>
---
src/PVE/SectionConfig.pm | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/src/PVE/SectionConfig.pm b/src/PVE/SectionConfig.pm
index 5c83d6a..7c27276 100644
--- a/src/PVE/SectionConfig.pm
+++ b/src/PVE/SectionConfig.pm
@@ -467,19 +467,23 @@ my sub add_property {
}
}
-=head3 $plugin->createSchema()
+=head3 $base->createSchema()
-=head3 $plugin->createSchema([ $skip_type, $base ])
+=head3 $base->createSchema([ $skip_type, $base ])
$schema = PVE::Example::Plugin->createSchema($skip_type, $base)
$schema = $class->createSchema($skip_type, $base)
-Returns the C<PVE::JSONSchema> used for I<creating> config entries of a
+Returns the C<L<PVE::JSONSchema>> used for I<creating> config entries of a
I<child plugin>.
This schema may then be used as desired, for example as the definition of
parameters of an API handler (C<POST>).
+B<NOTE:> This schema is universal for all registered plugins. This means that
+calling this method on different plugin instances will always return the same
+result.
+
=over
=item C<$skip_type> (optional)
--
2.47.3
More information about the pve-devel
mailing list