1 /******************************************************************************* 2 * Copyright (c) 2003, 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.osgi.service.resolver; 12 13 /** 14 * A state delta contains all the changes to bundles within a state. 15 * <p> 16 * Clients may implement this interface. 17 * </p> 18 * @since 3.1 19 */ 20 public interface StateDelta { 21 /** 22 * Returns an array of all the bundle deltas in this delta regardless of type. 23 * @return an array of bundle deltas 24 */ 25 public BundleDelta[] getChanges(); 26 27 /** 28 * Returns an array of all the members 29 * of this delta which match the given flags. If an exact match is requested 30 * then only delta members whose type exactly matches the given mask are 31 * included. Otherwise, all bundle deltas whose type's bit-wise and with the 32 * mask is non-zero are included. 33 * 34 * @param mask 35 * @param exact 36 * @return an array of bundle deltas matching the given match criteria. 37 */ 38 public BundleDelta[] getChanges(int mask, boolean exact); 39 40 /** 41 * Returns the state whose changes are represented by this delta. 42 * @return the state 43 */ 44 public State getState(); 45 } 46