Am 13.11.2013 um 10:04 schrieb zou zy <[email protected]>: > Hi, All > > Just like said in 2.1.6 of attached file, for HelloWordBuilder plugin source > code, the @Extension is at the inner class DescriptorImpl, rather than at the > outer class HelloWorldBuilder itself, Why? i cannot find the answer from the > wiki : https://wiki.jenkins-ci.org/display/JENKINS/Extend+Jenkins, can anyone > give me a help for this? >
I’m not sure but I think this has historical reasons: the @Extension has been added to Jenkins in 1.286. Before that date extensions have been registered using a different approach. (See Descriptor/Describable for more details) Why is that important for you? > By the way, do there have any special contract for the usage of @Extension > when writing hudson plugin? Yes: every class marked with an @Extension needs to subclass the corresponding extension point (that implements the interface ExtensionPoint). Here are all extension points: https://wiki.jenkins-ci.org/display/JENKINS/Extension+points BTW: please use the developer mailing list [email protected] for such questions > > Thanks. > > -- > You received this message because you are subscribed to the Google Groups > "Jenkins Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > <Writing-first-hudson-plugin.pdf>
signature.asc
Description: Message signed with OpenPGP using GPGMail
