Codota Logo
DescribableList.replace
Code IndexAdd Codota to your IDE (free)

How to use
replace
method
in
hudson.util.DescribableList

Best Java code snippets using hudson.util.DescribableList.replace (Showing top 10 results out of 315)

  • Common ways to obtain DescribableList
private void myMethod () {
DescribableList d =
  • Codota IconBuildableItemWithBuildWrappers biwbw;biwbw.getBuildWrappersList()
  • Codota IconSaveable owner;new DescribableList<ToolProperty<?>, ToolPropertyDescriptor>(owner)
  • Codota IconListView listView;new DescribableList<ViewJobFilter, Descriptor<ViewJobFilter>>(listView)
  • Smart code suggestions by Codota
}
origin: org.jenkins-ci.plugins/git

public void setBuildChooser(BuildChooser buildChooser) throws IOException {
  if (buildChooser.getClass()==DefaultBuildChooser.class) {
    getExtensions().remove(BuildChooserSetting.class);
  } else {
    getExtensions().replace(new BuildChooserSetting(buildChooser));
  }
}
origin: jenkinsci/pipeline-model-definition-plugin

public void set() throws IOException {
  List<EnvironmentVariablesNodeProperty.Entry> entries = new ArrayList<>(env.size());
  for (Map.Entry<String, String> entry : env.entrySet()) {
    entries.add(new EnvironmentVariablesNodeProperty.Entry(entry.getKey(), entry.getValue()));
  }
  EnvironmentVariablesNodeProperty newProperty = new EnvironmentVariablesNodeProperty(entries);
  DescribableList<NodeProperty<?>, NodePropertyDescriptor> nodeProperties = agent.getNodeProperties();
  nodeProperties.replace(newProperty);
}
origin: com.marvelution.jira.plugins/jenkins-jira-plugin

  response.getWriter().write("Successfully added a new JIRA Build Notifier");
} else if (!currentNotifier.postUrl.equals(postUrl)) {
  publishers.replace(currentNotifier, newNotifier);
  response.getWriter().write("Successfully replaced the existing JIRA Build Notifier");
} else {
origin: org.jvnet.hudson.main/hudson-core

pl.replace(new BuildTrigger(newChildProjects,
  existing==null?Result.SUCCESS:existing.getThreshold()));
origin: hudson/hudson-2.x

pl.replace(new BuildTrigger(newChildProjects,
  existing==null?Result.SUCCESS:existing.getThreshold()));
origin: org.eclipse.hudson/hudson-core

  continue;   // no need to touch
pl.replace(new BuildTrigger(newChildProjects,
  existing == null ? Result.SUCCESS : existing.getThreshold()));
origin: org.eclipse.hudson.main/hudson-core

  continue;   // no need to touch
pl.replace(new BuildTrigger(newChildProjects,
    existing == null ? Result.SUCCESS : existing.getThreshold()));
origin: org.jenkins-ci.plugins/git

getExtensions().replace(new PreBuildMerge(new UserMergeOptions(mergeOptions)));
mergeOptions = null;
origin: jenkinsci/mercurial-plugin

public MercurialInstallation createInstallation(JenkinsRule r, Version v, boolean debug, boolean useCaches, boolean useSharing, String config, Slave... slaves) throws IOException {
  MercurialInstallation.DescriptorImpl desc = r.jenkins.getDescriptorByType(MercurialInstallation.DescriptorImpl.class);
  ToolLocationNodeProperty.ToolLocation location = new ToolLocationNodeProperty.ToolLocation(desc, v.name(), "/opt/mercurial-" + v.exactVersion);
  MercurialInstallation inst = new MercurialInstallation(v.name(), "", "INSTALLATION/hg", debug, useCaches, useSharing, config, null);
  desc.setInstallations((MercurialInstallation[]) ArrayUtils.add(desc.getInstallations(), inst)); // TODO stop calling this here, should be responsibility of caller
  for (Slave slave : slaves) {
    DescribableList<NodeProperty<?>, NodePropertyDescriptor> props = slave.getNodeProperties();
    ToolLocationNodeProperty prop = props.get(ToolLocationNodeProperty.class);
    List<ToolLocationNodeProperty.ToolLocation> locations;
    if (prop == null) {
      locations = Collections.singletonList(location);
    } else {
      locations = new ArrayList<>(prop.getLocations());
      locations.add(location);
    }
    props.replace(new ToolLocationNodeProperty(locations));
  }
  return inst;
}
origin: jenkinsci/workflow-multibranch-plugin

assertEquals(1, releaseBuild.get().getNumber());
assertEquals(2, release.getNextBuildNumber());
top.getProperties().replace(new NoTriggerOrganizationFolderProperty("(?!master$).*"));
round3();
WorkflowMultiBranchProjectTest.showIndexing(p);
hudson.utilDescribableListreplace

Javadoc

Removes all instances of the same type, then add the new one.

Popular methods of DescribableList

  • get
  • toList
  • add
  • <init>
  • rebuild
  • remove
  • setOwner
  • getAll
  • toMap
    Creates a detached map from the current snapshot of the data, keyed from a descriptor to an instance
  • buildDependencyGraph
    Picks up DependecyDeclarers and allow it to build dependencies.
  • rebuildHetero
    Rebuilds the list by creating a fresh instances from the submitted form. This version works with the
  • addAll
  • rebuildHetero,
  • addAll,
  • isEmpty,
  • replaceBy,
  • addAllTo,
  • removeAll,
  • size,
  • onModified,
  • clear

Popular in Java

  • Reading from database using SQL prepared statement
  • compareTo (BigDecimal)
  • requestLocationUpdates (LocationManager)
  • addToBackStack (FragmentTransaction)
  • Graphics2D (java.awt)
    This Graphics2D class extends the Graphics class to provide more sophisticated control overgraphics
  • PrintStream (java.io)
    A PrintStream adds functionality to another output stream, namely the ability to print representatio
  • Queue (java.util)
    A collection designed for holding elements prior to processing. Besides basic java.util.Collection o
  • JTextField (javax.swing)
  • Table (org.hibernate.mapping)
    A relational table
  • SAXParseException (org.xml.sax)
    Encapsulate an XML parse error or warning.This exception may include information for locating the er
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now