platform35/org.eclipse.core.resources/src/org/eclipse/core/internal/resources/ResourceInfo.java
author timkelly
Thu, 30 Jul 2009 11:56:23 -0500
changeset 40 eb3c938c7fef
permissions -rw-r--r--
set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
40
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
     1
/*******************************************************************************
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
     2
 * Copyright (c) 2000, 2008 IBM Corporation and others.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
     3
 * All rights reserved. This program and the accompanying materials
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
     4
 * are made available under the terms of the Eclipse Public License v1.0
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
     5
 * which accompanies this distribution, and is available at
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
     6
 * http://www.eclipse.org/legal/epl-v10.html
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
     7
 * 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
     8
 * Contributors:
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
     9
 *     IBM Corporation - initial API and implementation
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    10
 *     Oakland Software Incorporated - added getSessionProperties and getPersistentProperties
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    11
 *******************************************************************************/
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    12
package org.eclipse.core.internal.resources;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    13
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    14
import java.io.*;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    15
import java.util.Map;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    16
import org.eclipse.core.internal.localstore.FileStoreRoot;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    17
import org.eclipse.core.internal.utils.*;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    18
import org.eclipse.core.internal.watson.IElementTreeData;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    19
import org.eclipse.core.resources.IResource;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    20
import org.eclipse.core.runtime.QualifiedName;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    21
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    22
/**
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    23
 * A data structure containing the in-memory state of a resource in the workspace.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    24
 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    25
public class ResourceInfo implements IElementTreeData, ICoreConstants, IStringPoolParticipant {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    26
	protected static final int LOWER = 0xFFFF;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    27
	protected static final int UPPER = 0xFFFF0000;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    28
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    29
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    30
	 * This field stores the resource modification stamp in the lower two bytes,
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    31
	 * and the character set generation count in the higher two bytes.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    32
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    33
	protected volatile int charsetAndContentId = 0;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    34
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    35
	/**
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    36
	 * The file system root that this resource is stored in
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    37
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    38
	protected FileStoreRoot fileStoreRoot;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    39
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    40
	/** Set of flags which reflect various states of the info (used, derived, ...). */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    41
	protected int flags = 0;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    42
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    43
	/** Local sync info */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    44
	// thread safety: (Concurrency004)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    45
	protected volatile long localInfo = I_NULL_SYNC_INFO;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    46
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    47
	/**
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    48
	 * This field stores the sync info generation in the lower two bytes, and
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    49
	 * the marker generation count in the upper two bytes.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    50
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    51
	protected volatile int markerAndSyncStamp;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    52
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    53
	/** The collection of markers for this resource. */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    54
	protected MarkerSet markers = null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    55
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    56
	/** Modification stamp */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    57
	protected long modStamp = 0;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    58
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    59
	/** Unique node identifier */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    60
	// thread safety: (Concurrency004)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    61
	protected volatile long nodeId = 0;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    62
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    63
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    64
	 * The properties which are maintained for the lifecycle of the workspace.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    65
	 * <p>
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    66
	 * This field is declared as the implementing class rather than the
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    67
	 * interface so we ensure that we get it right since we are making certain
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    68
	 * assumptions about the object type w.r.t. casting.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    69
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    70
	protected ObjectMap sessionProperties = null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    71
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    72
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    73
	 * The table of sync information. 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    74
	 * <p>
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    75
	 * This field is declared as the implementing class rather than the
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    76
	 * interface so we ensure that we get it right since we are making certain
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    77
	 * assumptions about the object type w.r.t. casting.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    78
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    79
	protected ObjectMap syncInfo = null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    80
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    81
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    82
	 * Returns the integer value stored in the indicated part of this info's flags.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    83
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    84
	protected static int getBits(int flags, int mask, int start) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    85
		return (flags & mask) >> start;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    86
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    87
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    88
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    89
	 * Returns the type setting for this info.  Valid values are 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    90
	 * FILE, FOLDER, PROJECT, 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    91
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    92
	public static int getType(int flags) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    93
		return getBits(flags, M_TYPE, M_TYPE_START);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    94
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    95
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    96
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    97
	 * Returns true if all of the bits indicated by the mask are set.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    98
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
    99
	public static boolean isSet(int flags, int mask) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   100
		return (flags & mask) == mask;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   101
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   102
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   103
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   104
	 * Clears all of the bits indicated by the mask.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   105
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   106
	public void clear(int mask) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   107
		flags &= ~mask;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   108
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   109
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   110
	public void clearModificationStamp() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   111
		modStamp = IResource.NULL_STAMP;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   112
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   113
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   114
	public synchronized void clearSessionProperties() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   115
		sessionProperties = null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   116
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   117
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   118
	public Object clone() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   119
		try {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   120
			return super.clone();
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   121
		} catch (CloneNotSupportedException e) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   122
			return null; // never gets here.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   123
		}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   124
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   125
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   126
	public int getCharsetGenerationCount() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   127
		return charsetAndContentId >> 16;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   128
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   129
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   130
	public int getContentId() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   131
		return charsetAndContentId & LOWER;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   132
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   133
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   134
	public FileStoreRoot getFileStoreRoot() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   135
		return fileStoreRoot;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   136
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   137
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   138
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   139
	 * Returns the set of flags for this info.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   140
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   141
	public int getFlags() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   142
		return flags;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   143
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   144
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   145
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   146
	 * Gets the local-relative sync information.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   147
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   148
	public long getLocalSyncInfo() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   149
		return localInfo;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   150
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   151
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   152
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   153
	 * Returns the marker generation count.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   154
	 * The count is incremented whenever markers on the resource change.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   155
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   156
	public int getMarkerGenerationCount() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   157
		return markerAndSyncStamp >> 16;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   158
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   159
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   160
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   161
	 * Returns a copy of the collection of makers on this resource.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   162
	 * <code>null</code> is returned if there are none.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   163
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   164
	public MarkerSet getMarkers() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   165
		return getMarkers(true);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   166
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   167
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   168
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   169
	 * Returns the collection of makers on this resource.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   170
	 * <code>null</code> is returned if there are none.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   171
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   172
	public MarkerSet getMarkers(boolean makeCopy) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   173
		if (markers == null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   174
			return null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   175
		return makeCopy ? (MarkerSet) markers.clone() : markers;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   176
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   177
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   178
	public long getModificationStamp() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   179
		return modStamp;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   180
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   181
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   182
	public long getNodeId() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   183
		return nodeId;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   184
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   185
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   186
	/**
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   187
	 * Returns the property store associated with this info.  The return value may be null.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   188
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   189
	public Object getPropertyStore() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   190
		return null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   191
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   192
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   193
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   194
	 * Returns a copy of the map of this resource session properties.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   195
	 * An empty map is returned if there are none.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   196
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   197
	public Map getSessionProperties() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   198
		// thread safety: (Concurrency001)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   199
		ObjectMap temp = sessionProperties;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   200
		if (temp == null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   201
			temp = new ObjectMap(5);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   202
		else
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   203
			temp = (ObjectMap) sessionProperties.clone();
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   204
		return temp;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   205
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   206
	
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   207
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   208
	 * Returns the value of the identified session property
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   209
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   210
	public Object getSessionProperty(QualifiedName name) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   211
		// thread safety: (Concurrency001)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   212
		Map temp = sessionProperties;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   213
		if (temp == null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   214
			return null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   215
		return temp.get(name);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   216
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   217
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   218
	/**
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   219
	 * The parameter to this method is the implementing class rather than the
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   220
	 * interface so we ensure that we get it right since we are making certain
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   221
	 * assumptions about the object type w.r.t. casting.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   222
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   223
	public synchronized ObjectMap getSyncInfo(boolean makeCopy) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   224
		if (syncInfo == null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   225
			return null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   226
		return makeCopy ? (ObjectMap) syncInfo.clone() : syncInfo;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   227
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   228
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   229
	public synchronized byte[] getSyncInfo(QualifiedName id, boolean makeCopy) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   230
		// thread safety: (Concurrency001)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   231
		byte[] b;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   232
		if (syncInfo == null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   233
			return null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   234
		b = (byte[]) syncInfo.get(id);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   235
		return b == null ? null : (makeCopy ? (byte[]) b.clone() : b);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   236
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   237
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   238
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   239
	 * Returns the sync information generation count.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   240
	 * The count is incremented whenever sync info on the resource changes.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   241
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   242
	public int getSyncInfoGenerationCount() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   243
		return markerAndSyncStamp & LOWER;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   244
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   245
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   246
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   247
	 * Returns the type setting for this info.  Valid values are 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   248
	 * FILE, FOLDER, PROJECT, 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   249
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   250
	public int getType() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   251
		return getType(flags);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   252
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   253
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   254
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   255
	 * Increments the charset generation count.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   256
	 * The count is incremented whenever the encoding on the resource changes.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   257
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   258
	public void incrementCharsetGenerationCount() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   259
		//increment high order bits
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   260
		charsetAndContentId = ((charsetAndContentId + LOWER + 1) & UPPER) + (charsetAndContentId & LOWER);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   261
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   262
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   263
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   264
	 * Mark this resource info as having changed content
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   265
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   266
	public void incrementContentId() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   267
		//increment low order bits
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   268
		charsetAndContentId = (charsetAndContentId & UPPER) + ((charsetAndContentId + 1) & LOWER);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   269
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   270
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   271
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   272
	 * Increments the marker generation count.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   273
	 * The count is incremented whenever markers on the resource change.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   274
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   275
	public void incrementMarkerGenerationCount() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   276
		//increment high order bits
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   277
		markerAndSyncStamp = ((markerAndSyncStamp + LOWER + 1) & UPPER) + (markerAndSyncStamp & LOWER);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   278
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   279
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   280
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   281
	 * Change the modification stamp to indicate that this resource has changed.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   282
	 * The exact value of the stamp doesn't matter, as long as it can be used to
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   283
	 * distinguish two arbitrary resource generations.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   284
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   285
	public void incrementModificationStamp() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   286
		modStamp++;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   287
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   288
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   289
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   290
	 * Increments the sync information generation count.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   291
	 * The count is incremented whenever sync info on the resource changes.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   292
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   293
	public void incrementSyncInfoGenerationCount() {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   294
		//increment low order bits
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   295
		markerAndSyncStamp = (markerAndSyncStamp & UPPER) + ((markerAndSyncStamp + 1) & LOWER);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   296
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   297
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   298
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   299
	 * Returns true if all of the bits indicated by the mask are set.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   300
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   301
	public boolean isSet(int mask) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   302
		return (flags & mask) == mask;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   303
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   304
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   305
	public void readFrom(int newFlags, DataInput input) throws IOException {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   306
		// The flags for this info are read by the visitor (flattener). 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   307
		// See Workspace.readElement().  This allows the reader to look ahead 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   308
		// and see what type of info is being loaded.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   309
		this.flags = newFlags;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   310
		localInfo = input.readLong();
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   311
		nodeId = input.readLong();
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   312
		charsetAndContentId = input.readInt() & LOWER;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   313
		modStamp = input.readLong();
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   314
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   315
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   316
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   317
	 * Sets all of the bits indicated by the mask.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   318
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   319
	public void set(int mask) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   320
		flags |= mask;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   321
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   322
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   323
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   324
	 * Sets the value of the indicated bits to be the given value.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   325
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   326
	protected void setBits(int mask, int start, int value) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   327
		int baseMask = mask >> start;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   328
		int newValue = (value & baseMask) << start;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   329
		// thread safety: (guarantee atomic assignment)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   330
		int temp = flags;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   331
		temp &= ~mask;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   332
		temp |= newValue;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   333
		flags = temp;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   334
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   335
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   336
	public void setFileStoreRoot(FileStoreRoot fileStoreRoot) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   337
		this.fileStoreRoot = fileStoreRoot;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   338
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   339
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   340
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   341
	 * Sets the flags for this info.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   342
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   343
	protected void setFlags(int value) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   344
		flags = value;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   345
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   346
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   347
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   348
	 * Sets the local-relative sync information.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   349
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   350
	public void setLocalSyncInfo(long info) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   351
		localInfo = info;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   352
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   353
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   354
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   355
	 * Sets the collection of makers for this resource.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   356
	 * <code>null</code> is passed in if there are no markers.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   357
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   358
	public void setMarkers(MarkerSet value) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   359
		markers = value;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   360
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   361
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   362
	/**
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   363
	 * Sets the resource modification stamp.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   364
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   365
	public void setModificationStamp(long value) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   366
		this.modStamp = value;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   367
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   368
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   369
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   370
	 *
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   371
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   372
	public void setNodeId(long id) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   373
		nodeId = id;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   374
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   375
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   376
	/**
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   377
	 * Sets the property store associated with this info.  The value may be null.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   378
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   379
	public void setPropertyStore(Object value) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   380
		// needs to be implemented on subclasses
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   381
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   382
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   383
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   384
	 * Sets the identified session property to the given value.  If
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   385
	 * the value is null, the property is removed.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   386
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   387
	public synchronized void setSessionProperty(QualifiedName name, Object value) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   388
		// thread safety: (Concurrency001)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   389
		if (value == null) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   390
			if (sessionProperties == null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   391
				return;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   392
			ObjectMap temp = (ObjectMap) sessionProperties.clone();
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   393
			temp.remove(name);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   394
			if (temp.isEmpty())
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   395
				sessionProperties = null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   396
			else
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   397
				sessionProperties = temp;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   398
		} else {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   399
			ObjectMap temp = sessionProperties;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   400
			if (temp == null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   401
				temp = new ObjectMap(5);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   402
			else
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   403
				temp = (ObjectMap) sessionProperties.clone();
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   404
			temp.put(name, value);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   405
			sessionProperties = temp;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   406
		}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   407
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   408
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   409
	/**
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   410
	 * The parameter to this method is the implementing class rather than the
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   411
	 * interface so we ensure that we get it right since we are making certain
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   412
	 * assumptions about the object type w.r.t. casting.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   413
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   414
	protected void setSyncInfo(ObjectMap syncInfo) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   415
		this.syncInfo = syncInfo;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   416
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   417
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   418
	public synchronized void setSyncInfo(QualifiedName id, byte[] value) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   419
		if (value == null) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   420
			//delete sync info
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   421
			if (syncInfo == null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   422
				return;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   423
			syncInfo.remove(id);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   424
			if (syncInfo.isEmpty())
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   425
				syncInfo = null;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   426
		} else {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   427
			//add sync info
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   428
			if (syncInfo == null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   429
				syncInfo = new ObjectMap(5);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   430
			syncInfo.put(id, value.clone());
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   431
		}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   432
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   433
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   434
	/** 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   435
	 * Sets the type for this info to the given value.  Valid values are 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   436
	 * FILE, FOLDER, PROJECT
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   437
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   438
	public void setType(int value) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   439
		setBits(M_TYPE, M_TYPE_START, value);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   440
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   441
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   442
	/* (non-Javadoc
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   443
	 * Method declared on IStringPoolParticipant
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   444
	 */
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   445
	public void shareStrings(StringPool set) {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   446
		ObjectMap map = syncInfo;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   447
		if (map != null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   448
			map.shareStrings(set);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   449
		map = sessionProperties;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   450
		if (map != null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   451
			map.shareStrings(set);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   452
		MarkerSet markerSet = markers;
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   453
		if (markerSet != null)
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   454
			markerSet.shareStrings(set);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   455
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   456
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   457
	public void writeTo(DataOutput output) throws IOException {
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   458
		// The flags for this info are written by the visitor (flattener). 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   459
		// See SaveManager.writeElement().  This allows the reader to look ahead 
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   460
		// and see what type of info is being loaded.
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   461
		output.writeLong(localInfo);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   462
		output.writeLong(nodeId);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   463
		output.writeInt(getContentId());
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   464
		output.writeLong(modStamp);
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   465
	}
eb3c938c7fef set up for custom build for logging. merged from carbide 2.1.x builds. this state is as it comes from platform. Next changelog will add the updates.
timkelly
parents:
diff changeset
   466
}