/** * Returns true if this is a instance URN. * * @return if this is a instance URN. */ public boolean instanceURN() { return instanceName() != null; }
@Override protected void preStart() { mService = Executors.newCachedThreadPool( new NamedThreadFactory(new StringBuilder( ASYNC_THREAD_NAME_PREFIX).append("-").append( //$NON-NLS-1$ getURN().instanceName()).toString())); }
if(inURN.instanceURN()) { String value = p.getProperty(inURN.instanceName() + "." + inAttribute); //$NON-NLS-1$ if(value != null) {
? inRequester.providerName() : inURN.providerName(); String instanceName = THIS.equals(inURN.instanceName()) ? inRequester.instanceName() : inURN.instanceName(); if(providerType == null && providerName == null &&
boolean noProviderName = inURN.providerName() == null || inURN.providerName().isEmpty(); boolean noInstanceName = inURN.instanceName() == null || inURN.instanceName().isEmpty(); inURN.providerName().equals(i.providerName())) && (noInstanceName || inURN.instanceName().equals(i.instanceName()))) { if (returnValue == null) { returnValue = get(i);
/** * Validates the module instance URN. * * @param inURN the module instance URN. * @param inProviderURN the module provider URN. If not null, * the module URN is verified to have this URN as its prefix. * * @throws InvalidURNException if the module URN is invalid. */ public static void validateInstanceURN(ModuleURN inURN, ModuleURN inProviderURN) throws InvalidURNException { validateProviderURN(inURN, Messages.INCOMPLETE_INSTANCE_URN, true); if(!inURN.instanceURN()) { throw new InvalidURNException(new I18NBoundMessage1P( Messages.INCOMPLETE_INSTANCE_URN, inURN.toString())); } String instanceName = inURN.instanceName(); if(!isValidIdentifier(instanceName)) { throw new InvalidURNException(new I18NBoundMessage2P( Messages.INVALID_INSTANCE_URN, inURN.toString(), instanceName)); } if (inProviderURN != null) { validateInstanceOf(inURN, inProviderURN); } }
source, parameters, getURN().instanceName(), this); strategy.start();