Vector removeElement - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Vector removeElement method.

This code example shows how to use the following methods:indexOf, removeElement, size
 
    public void closeFrame(final JInternalFrame f) {
        if (f == fCurrentFrame) {
            activateNextFrame(); 
        } 
        fChildFrames.removeElement(f);
        super.closeFrame(f);
    } 
 
    public void deiconifyFrame(final JInternalFrame f) {
        JInternalFrame.JDesktopIcon desktopIcon;
 
        desktopIcon = f.getDesktopIcon();
        // If the icon moved, move the frame to that spot before expanding it 
        // reshape does delta checks for us 
        f.reshape(desktopIcon.getX(), desktopIcon.getY(), f.getWidth(), f.getHeight());
        super.deiconifyFrame(f);
    } 
 
    void addIcon(final Container c, final JInternalFrame.JDesktopIcon desktopIcon) {

6
CodeRank
This code example shows how to use the following methods:elementAt, indexOf, removeElement, size
 
    public void closeFrame(final JInternalFrame f) {
        if (f == fCurrentFrame) {
            activateNextFrame(); 
        } 
        fChildFrames.removeElement(f);
        super.closeFrame(f);
    } 
 
    public void deiconifyFrame(final JInternalFrame f) {
        JInternalFrame.JDesktopIcon desktopIcon;
 
        desktopIcon = f.getDesktopIcon();
        // If the icon moved, move the frame to that spot before expanding it 
        // reshape does delta checks for us 
        f.reshape(desktopIcon.getX(), desktopIcon.getY(), f.getWidth(), f.getHeight());
        super.deiconifyFrame(f);
    } 
 
    void addIcon(final Container c, final JInternalFrame.JDesktopIcon desktopIcon) {

6
CodeRank
This code example shows how to use the following methods:addElement, removeElement
    Vector v = new Vector();
    String submit = null;
    String item = null;
     
    private void addItem(String name) {
	v.addElement(name);
    } 
 
    private void removeItem(String name) {
	v.removeElement(name);
    } 
 
    public void setItem(String name) {
	item = name;
    } 
     
    public void setSubmit(String s) {
	submit = s;
    } 
 
6
CodeRank
This code example shows how to use the following methods:lastElement, removeElement
        commands.addElement(command); 
        command.execute(); 
    } 
 
    public void undoLastCommand() { 
        final Command lastCommand = commands.lastElement(); 
        lastCommand.undo(); 
        commands.removeElement(lastCommand); 
    } 
 
    public String descriptionOfUndo() { 
        final Command lastCommand = commands.lastElement(); 
        return lastCommand.getDescription(); 
    } 
 
    public boolean isEmpty() { 
        return commands.isEmpty(); 
    } 
 
    public String getNameOfUndo() { 
6
CodeRank
This code example shows how to use the following methods:push, firstElement, removeElement, size
This code example shows how to use the following methods:isEmpty, removeElement
     */ 
    public void removeComponent(ProductRef component) {
        if (_components == null) {
            return; 
        } 
        _components.removeElement(component);
 
        if (_components.isEmpty()) {
            _components = null;
        } 
    } 
 
    /** 
     * Returns the number of components available in the product 
     */ 
    public int getNumComponents() { 
        return (_components == null) ? 0 : _components.size();
    } 
 
    /** 
6
CodeRank
This code example shows how to use the following methods:removeElement
 
  /** 
   *  Performs the same function as Vector.removeElement () 
   **/ 
  public boolean removeElement (EntryEdit entry_edit) { 
    return vector.removeElement (entry_edit); 
  } 
 
  /** 
   *  Performs the same function as Vector.removeElement () 
   **/ 
  public int indexOf (EntryEdit entry_edit) { 
    return vector.indexOf (entry_edit); 
  } 
 
  /** 
   *  Performs the same function as Vector.size () 
   */ 
  public int size () { 
    return vector.size (); 
6
CodeRank
This code example shows how to use the following methods:removeElement, size
 
    @Override 
    public void clearBusy(final View view) {
        if (view.getContent().isObject()) {
            final ObjectAdapter object = ((ObjectContent) view.getContent()).getObject();
            busy.removeElement(object);
            // showDefaultCursor(); 
        } 
        showBusyState(view);
 
        if (busy.size() == 0) {
            message = "";
            viewer.forcePaintOfStatusBar();
        } 
    } 
 
    @Override 
    public boolean isBusy(final View view) {
        if (view != null) {
            final Content content = view.getContent();
5
CodeRank
This code example shows how to use the following methods:contains, removeElement
     * Handles click on checkbox for a list item. 
     * @param chkBox Checkbox view 
     * @param id Id assigned to the list item 
     */ 
    protected void toggleCheck(CheckBox chkBox, int id) {
        if (mSelectedItems.contains(id)) {
            mSelectedItems.removeElement(id);
        } else { 
            mSelectedItems.add(id);
        } 
        chkBox.setChecked(mSelectedItems.contains(id));
    } 
 
    /** 
     * Returns the ids of the selected list items. 
     * @return List of ids of selected list items. 
     */ 
    public Vector<Integer> getSelectedItems() {
        return mSelectedItems;
    } 
6
CodeRank
This code example shows how to use the following methods:removeElement
  /** 
   *  Performs the same function as Vector.removeElement() 
   **/ 
  protected boolean removeElement(Entry entry) 
  { 
    return vector.removeElement(entry);
  } 
 
  /** 
   *  Return true if this object contains the given Entry. 
   **/ 
  public boolean contains(Entry entry) 
  { 
    if(indexOf(entry) == -1) 
      return false; 
    else  
      return true; 
  } 
 
  /** 
6
CodeRank

Related Vector removeElement Questions & Answers:

removeElement Method Overview
Removes the first (lowest-indexed) occurrence of the argument from this vector.
See Code Examples for other Java 8 Vector Methods: