I must be having a bad day, but I can't figure out why this isn't working.

HPI plugin reduced to *only* 1 class and the jelly file (both below).

Config is being correctly set. Config is being correctly saved to the
plugin config.xml. Config is *not* being loaded/displayed in the UI,
however. Why?

---

public class HelloWorldPlugin extends Plugin implements
Describable<HelloWorldPlugin>{
  private String fish;

  public String getFish() {
    return fish;
  }

  @DataBoundSetter public void setFish(String fish) {
    this.fish = fish;
  }


  /**
   * Returns this singleton instance.
   *
   * @return the singleton.
   */
  public static HelloWorldPlugin get() {
    return Jenkins.getInstance().getPlugin(HelloWorldPlugin.class);
  }

  @Override
  public void start() throws Exception {
    load();
  }

  @Override
  public void configure(StaplerRequest req, JSONObject formData)
throws IOException,

 ServletException, Descriptor.FormException {
    req.bindJSON(this, formData);
    save();
  }

  @Override
  public Descriptor<HelloWorldPlugin> getDescriptor() {
    return Jenkins.getInstance().getDescriptorOrDie(HelloWorldPlugin.class);
  }

  @Extension
  public static class DescriptorImpl extends Descriptor<HelloWorldPlugin> {

    @Override
    public String getDisplayName() {
      return "HelloWorldPlugin Plugin";
    }
  }
}

<?jelly escape-by-default='true'?>
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler"
xmlns:d="jelly:define" xmlns:l="/lib/layout" xmlns:t="/lib/hudson"
xmlns:f="/lib/form">
    <f:entry title="Fish" field="fish">
        <f:textbox/>
    </f:entry>
</j:jelly>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-dev/CAPYP83S4M4we-yUqxWfrUvf4K6_rVJoVhs5wz-9HbcXAh1EiQw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to