1 /******************************************************************************* 2 * Copyright (c) 2000, 2005 IBM Corporation and others. 3 * All rights reserved. This program and the accompanying materials 4 * are made available under the terms of the Eclipse Public License v1.0 5 * which accompanies this distribution, and is available at 6 * http://www.eclipse.org/legal/epl-v10.html 7 * 8 * Contributors: 9 * IBM Corporation - initial API and implementation 10 *******************************************************************************/ 11 package org.eclipse.core.internal.indexing; 12 13 public abstract class AbstractPagePolicy { 14 15 /** 16 * Returns a page given a page number, a buffer, and the page store. The 17 * buffer should be copied in the implementations as it may be reused later. 18 * The buffer is extended or truncated to the page size during this copy. 19 * Both the buffer contents and the page number can be used to determine 20 * the type of page to create. 21 */ 22 public abstract Page createPage(int pageNumber, byte[] buffer, PageStore pageStore); 23 24 } 25