net_lemats_gallery_ThumbsViewList = Class.create();
net_lemats_gallery_ThumbsViewList.prototype = {

    initialize : function() {
		/** Array für Positionen der Thumbs */
		this._pos = new Array();
		this.maxSize = net_lemats_gallery_Album.NUM_OF_THMBS;
    },
    
	addLast : function(/*String*/ thumbID) {
		var ret = this._pos.length >= this.maxSize ? this._pos.shift() : null;
		this._pos.push(thumbID);
		return ret;
	},
	
	addFirst : function(/*String*/ thumbID) {		
		var ret = this._pos.length >= this.maxSize ? this._pos.pop() : null;
		this._pos.unshift(thumbID);
		return ret;
	},
	
	getLast : function() {
		return this._pos[this._pos.length-1];
	},
	
	getFirst : function() {
		return this._pos[0];
	}

}
