boolean validOS = (osStamp.equals(RegistryProperties.getProperty(IRegistryConstants.PROP_OS))); boolean validWS = (windowsStamp.equals(RegistryProperties.getProperty(IRegistryConstants.PROP_WS))); boolean validNL = (localeStamp.equals(RegistryProperties.getProperty(IRegistryConstants.PROP_NL)));
boolean validOS = (osStamp.equals(RegistryProperties.getProperty(IRegistryConstants.PROP_OS, RegistryProperties.empty))); boolean validWS = (windowsStamp.equals(RegistryProperties.getProperty(IRegistryConstants.PROP_WS, RegistryProperties.empty))); boolean validNL = (localeStamp.equals(RegistryProperties.getProperty(IRegistryConstants.PROP_NL, RegistryProperties.empty)));
	private boolean checkCacheValidity(DataInputStream in, long expectedTimestamp) {		int version;		try {			version = in.readInt();			if (version != CACHE_VERSION)				return false;			long installStamp = in.readLong();			long registryStamp = in.readLong();			long mainDataFileSize = in.readLong();			long extraDataFileSize = in.readLong();			long contributionsFileSize = in.readLong();			long contributorsFileSize = in.readLong();			long namespacesFileSize = in.readLong();			long orphansFileSize = in.readLong();			String osStamp = in.readUTF();			String windowsStamp = in.readUTF();			String localeStamp = in.readUTF();			boolean validTime = (expectedTimestamp == 0 || expectedTimestamp == registryStamp);			boolean validInstall = (installStamp == registry.computeState());			boolean validOS = (osStamp.equals(RegistryProperties.getProperty(IRegistryConstants.PROP_OS)));			boolean validWS = (windowsStamp.equals(RegistryProperties.getProperty(IRegistryConstants.PROP_WS)));			boolean validNL = (localeStamp.equals(RegistryProperties.getProperty(IRegistryConstants.PROP_NL)));			if (!validTime || !validInstall || !validOS || !validWS || !validNL)				return false;			boolean validMain = (mainDataFileSize == mainDataFile.length());			boolean validExtra = (extraDataFileSize == extraDataFile.length());			boolean validContrib = (contributionsFileSize == contributionsFile.length());			boolean validContributors = (contributorsFileSize == contributorsFile.length());			boolean validNamespace = (namespacesFileSize == namespacesFile.length());			boolean validOrphan = (orphansFileSize == orphansFile.length());			return (validMain && validExtra && validContrib && validContributors && validNamespace && validOrphan);		} catch (IOException e) {			log(new Status(IStatus.ERROR, RegistryMessages.OWNER_NAME, fileError, RegistryMessages.meta_registryCacheInconsistent, e));			return false;		}	}