function FilterList() {
	
	var items = [];
	
	var defaultFilter = function (item) {
		return item;
	}
	
	var filter = defaultFilter;
	
	this .getItems = function () {
		var result = [];
		
		$.each(items, function (i, item) {
			var t = filter.call(this, item);
			if (t != null) {
				result.push(t);
			}
		});
		
		return result;
	}
	
	this .getAllItems = function () {
		return items;
	}
	
	this .addItem = function (i) {
		items.push(i);
	}
	
	this .setFilter = function (f) {
		filter = f;
		
		if (filter == null) {
			filter = defaultFilter;
		}
	}
}

function Point(id, name, group, coordinates, details, distance) {
	
	this .getName = function () {
		return name;
	}
	
	this .getGroup = function () {
		return group;
	}
	
	this .getCoordinates = function () {
		return coordinates;
	}
	
	this .getId = function () {
		return id;
	}
	
	this .getDetails = function () {
		return details;
	}
	
	this .getMarker = function () {
		return marker;
	}
	
	this .setMarker = function (m) {
		marker = m;
	}
	
	var details = details;
	
	var id = id;
	
	var name = name;
	
	var group = group;
	
	var coordinates = coordinates;
	
	var distance = distance;
	
	var marker;
}
