Adds a menu item at the given position.<p>

@param item the item
@param position the position

@see org.opencms.workplace.tools.CmsIdentifiableObjectContainer#addIdentifiableObject(String, Object, float)
492243
public void addMenuItem(CmsAdminMenuItem item, float position) {

        m_container.addIdentifiableObject(item.getId(), item, position);
    }
136321
public void addActionComponent( JComponent item )
  {
    if( !SwingUtilities.isEventDispatchThread() )
    {
      throw new RuntimeException( "Whoops!  UpdateNotifier is restricted to the EventDispatch thread." );
    }
    _mapItems.put( item, null );
  }
1102398
public FastAdapterBottomSheetDialog<Item> add(int position, List<Item> items) {
        mItemAdapter.add(position, items);
        return this;
    }
9997
@Override
    public final Object instantiateItem(final ViewGroup container, final int position) {
        if (Constants.DEBUG) {
            Log.i("InfiniteViewPager", String.format("instantiating position %s", position));
        }
        final PageModel<T> model = createPageModel(position);
        mPageModels[position] = model;
        container.addView(model.getParentView());
        return model;
    }
1373807
protected void onItemClick(View view, int position){
        if(itemClickListener != null) itemClickListener.onItemClick(view, getItem(position), position);
    }
203667
public TableWriteItems addItemToPut(Item item) {
        if (item != null) {
            if (itemsToPut == null)
                itemsToPut = new ArrayList<Item>();
            this.itemsToPut.add(item);
        }
        return this;
    }
1020988
public void updateItem (T item)
    {
        if (_items == null) {
            return;
        }
        int idx = _items.indexOf(item);
        if (idx == -1) {
            _items.add(0, item);
        } else {
            _items.set(idx, item);
        }
    }
10548
public void addAdminTool(CmsTool adminTool, float position) {

        m_container.addIdentifiableObject(adminTool.getId(), adminTool, position);
    }
549772
def insert(self, position, item, select=False):
        
        if item in self:
            raise ValueError("item %s already in list" % item)
        modeliter = self.model.insert(position, (item,))
        self._id_to_iter[id(item)] = modeliter
        if select:
            self.selected_item = item
        self.emit('item-inserted', item, position)
963140
@Override
	public void add(int location, T object)
	{
		list.add(location, object);
		onModification();
	}
785285
public void addItemDetails(CmsListItemDetails itemDetail) {

        itemDetail.setListId(getListId());
        m_itemDetails.addIdentifiableObject(itemDetail.getId(), itemDetail);
    }
825734
protected void addItem(ItemState item)
   {
      index.put(item.getData().getIdentifier(), item);
      index.put(item.getData().getQPath(), item);
      index.put(new ParentIDQPathBasedKey(item), item);
      index.put(new IDStateBasedKey(item.getData().getIdentifier(), item.getState()), item);

      if (item.getData().isNode())
      {
         Map<String, ItemState> children = lastChildNodeStates.get(item.getData().getParentIdentifier());
         if (children == null)
         {
            children = new HashMap<String, ItemState>();
            lastChildNodeStates.put(item.getData().getParentIdentifier(), children);
         }
         children.put(item.getData().getIdentifier(), item);

         List<ItemState> listItemState = childNodeStates.get(item.getData().getParentIdentifier());
         if (listItemState == null)
         {
            listItemState = new ArrayList<ItemState>();
            childNodeStates.put(item.getData().getParentIdentifier(), listItemState);
         }
         listItemState.add(item);
         if (item.isPathChanged())
         {
            if (allPathsChanged == null)
            {
               allPathsChanged = new ArrayList<ItemState>();
            }
            allPathsChanged.add(item);
         }
      }
      else
      {
         Map<String, ItemState> children = lastChildPropertyStates.get(item.getData().getParentIdentifier());
         if (children == null)
         {
            children = new HashMap<String, ItemState>();
            lastChildPropertyStates.put(item.getData().getParentIdentifier(), children);
         }
         children.put(item.getData().getIdentifier(), item);

         List<ItemState> listItemState = childPropertyStates.get(item.getData().getParentIdentifier());
         if (listItemState == null)
         {
            listItemState = new ArrayList<ItemState>();
            childPropertyStates.put(item.getData().getParentIdentifier(), listItemState);
         }
         listItemState.add(item);
      }

      if (item.isNode() && item.isPersisted())
      {
         int[] childInfo = childNodesInfo.get(item.getData().getParentIdentifier());
         if (childInfo == null)
         {
            childInfo = new int[2];
         }

         if (item.isDeleted())
         {
            --childInfo[CHILD_NODES_COUNT];
         }
         else if (item.isAdded())
         {
            ++childInfo[CHILD_NODES_COUNT];
            childInfo[CHILD_NODES_LAST_ORDER_NUMBER] = ((NodeData)item.getData()).getOrderNumber();

         }
         childNodesInfo.put(item.getData().getParentIdentifier(), childInfo);
      }
   }
517776
public function insertItem($item,$position=0){
		$itemO=$this->beforeAddItem($item);
		 $start = array_slice($this->items, 0, $position);
		 $end = array_slice($this->items, $position);
		 $start[] = $item;
		 $this->items=array_merge($start, $end);
		 return $itemO;
	}
166058
public function addAt(Item $item, $position = null)
    {
        if (0 === $position) {
            array_unshift($this->items, $item);
        } else if (null === $position) {
            $this->items[] = $item;
        } else if (count($this->items) <= $position) {
            $this->items[] = $item;
        } else {
            array_splice($this->items, $position, 0, [$item]);
        }

        $this->isUpdated = true;

        return $this;
    }
616086
function addItem(item = {}) {
    if (!item.id) {
        console.warn('Cannot add menuitem. A unique identifier is required for the menuitem to work correctly.');
        return;
    }
    let el = doc.createElement('menuItem');
    // assign unique id
    item.attributes = _.assign({}, item.attributes, {
        id: item.id
    });
    // add all attributes
    setAttributes(el, item.attributes);
    // add title
    el.innerHTML = `<title>${(_.isFunction(item.name) ? item.name() : item.name)}</title>`;
    // add page reference
    el.page = item.page;
    // appends to the menu
    menuBarEl.insertBefore(el, null);
    // cache for later use
    itemsCache[item.id] = el;

    return el;
}
455225
@Override
    public long getItemId(int position) {
        if (shouldInsertItemAtPosition(position)) {
            return getItem(position).getIdentifier();
        } else {
            return mAdapter.getItemId(position - itemInsertedBeforeCount(position));
        }
    }
462802
void add(T item) {
    int i = nextIndex.getAndIncrement() % data.length();
    data.set(i, item);
  }