Checks for the existence of a conversion method.
@param destination destination field
@param source source field
@return true if the conversion method exists, false otherwise
197148
public boolean fieldsToCheck(Field destination, Field source){
		destinationName = destination.getName();
		sourceName = source.getName();
		if(!xml.conversionsLoad().isEmpty()){
			configurationType = XML;
			if(config == DESTINATION){
				if(existsXmlConversion(destinationClass)) { membership = Membership.DESTINATION;  return true;}
				if(existsXmlConversion(sourceClass))      { membership = Membership.SOURCE;       return true;}}
			else{
				if(existsXmlConversion(sourceClass))      { membership = Membership.SOURCE;       return true;}
				if(existsXmlConversion(destinationClass)) { membership = Membership.DESTINATION;  return true;}}
		}
		configurationType = ANNOTATION;
		if(config == DESTINATION){
			if(existsAnnotatedConversion(destinationClass)) { membership = Membership.DESTINATION;  return true;}
			if(existsAnnotatedConversion(sourceClass))      { membership = Membership.SOURCE;       return true;}}
		else{
			if(existsAnnotatedConversion(sourceClass))      { membership = Membership.SOURCE;       return true;}
			if(existsAnnotatedConversion(destinationClass)) { membership = Membership.DESTINATION;  return true;}}
		return false;
	}
652988
public static void configNotPresent(Class<?> destination,Class<?> source,XML xml){
		throw new MappingNotFoundException(MSG.INSTANCE.message(Constants.mappingNotFoundException2path,destination.getSimpleName(), source.getSimpleName(),xml.getXmlPath()));
	}
240798
@Override
  public B writeTo(Destination destination) {
    super.writeTo(destination);
    fromState(destination.getProperties());
    return typedSelf();
  }
643388
public DestinationHandler getAliasDestinationInternal(String aliasName, String aliasBus, AliasChainValidator validator, DestinationHandler targetDest, boolean includeInvisible)
                    throws SITemporaryDestinationNotFoundException, SINotPossibleInCurrentConfigurationException, SIMPDestinationCorruptException, SIResourceException
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(tc, "getAliasDestination", new Object[] { aliasName, aliasName, targetDest, Boolean.valueOf(includeInvisible) });

        DestinationHandler destinationHandler = getDestinationInternal(aliasName, aliasBus, includeInvisible);

        try
        {
            if (destinationHandler == null)
            {
                BaseDestinationDefinition bdd = messageProcessor.getMessagingEngine().getSIBDestination(aliasBus, aliasName);

                // The returned destination can be remote or an alias.  We need to act
                // accordingly.
                if (bdd.isAlias())
                {
                    // The destination is an alias.
                    DestinationAliasDefinition add = (DestinationAliasDefinition) bdd;

                    destinationHandler = createAliasDestination(add, validator, targetDest);
                }
            }
        }

        // Catch Admin's SIBExceptionDestinationNotFound exception
        catch (SIBExceptionDestinationNotFound e)
        {
            // No FFDC code needed

            SibTr.exception(tc, e);

            // Exception not fatal - just return null to show no destiation has been
            // found.
        } catch (SIBExceptionBase e)
        {
            // No FFDC code needed

            SibTr.exception(tc, e);

            // TO DO - handle this
        } catch (SIResourceException e)
        {
            // No FFDC code needed
            if (!(e instanceof SIMPResourceException))
            {
                SIMPResourceException ee = new SIMPResourceException(e);
                ee.setExceptionReason(SIRCConstants.SIRC0901_INTERNAL_MESSAGING_ERROR);
                ee.setExceptionInserts(new String[] { "com.ibm.ws.sib.processor.impl.DestinationManager.getAliasDestination",
                                                     "1:8188:1.508.1.7",
                                                     SIMPUtils.getStackTrace(e) });
                if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
                    SibTr.exit(tc, "getAliasDestination", ee);
                throw ee;
            }

            if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
                SibTr.exit(tc, "getAliasDestination", e);
            throw e;

        }

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(tc, "getAliasDestination", destinationHandler);

        return destinationHandler;
    }
843124
public Object get(IConverter converter, Object sourceObject,
			TypeReference<?> destinationType) {
		return convertedObjects.get(new ConvertedObjectsKey(converter,
				sourceObject, destinationType));
	}
1213785
public static void classesNotConfigured(Class<?> destination,Class<?> source){
		throw new MappingNotFoundException(MSG.INSTANCE.message(Constants.mappingNotFoundException2,destination.getSimpleName(), source.getSimpleName()));
	}
1175019
@Override
	public final MessageConsumer createConsumer(Destination destination) throws JMSException
    {
        return createConsumer(destination,null,false);
    }
807441
public boolean canConvert(Class<?> sourceType, Class<?> targetType) {
		Assert.notNull(targetType, "targetType to convert to cannot be null");
		return canConvert((sourceType != null ? TypeDescriptor.valueOf(sourceType) : null),
				TypeDescriptor.valueOf(targetType));
	}
925163
@Override
    public void moveObject(final FedoraSession session, final String source, final String destination) {
        final Session jcrSession = getJcrSession(session);
        try {
            final FedoraResource srcResource = find(session, source);
            final Node sourceNode = getJcrNode(srcResource);
            final String name = sourceNode.getName();
            final Node parent = sourceNode.getDepth() > 0 ? sourceNode.getParent() : null;

            jcrSession.getWorkspace().move(source, destination);

            if (parent != null) {
                createTombstone(parent, name);
            }

            touchLdpMembershipResource(getJcrNode(find(session, source)));
            touchLdpMembershipResource(getJcrNode(find(session, destination)));

        } catch (final RepositoryException e) {
            throw new RepositoryRuntimeException(e);
        }
    }
1012196
@Override
	protected final void sendToDestination(Destination destination, boolean destinationOverride, Message srcMessage, int deliveryMode, int priority, long timeToLive) throws JMSException
    {
        // Check that the destination was specified
        if (destination == null)
            throw new InvalidDestinationException("Destination not specified");  // [JMS SPEC]

        // Create an internal copy if necessary
        AbstractMessage message = MessageTools.makeInternalCopy(srcMessage);
        
        externalAccessLock.readLock().lock();
        try
		{
    		checkNotClosed();
    		
	        // Dispatch to session
            ((LocalSession)session).dispatch(message);
		}
        finally
        {
        	externalAccessLock.readLock().unlock();
        }
    }
407866
public boolean convert(File source, File destination) {
        boolean result = true;
        if (source.isDirectory()) {
            if (source.getName().startsWith(".")) {
                // skip "hidden" directories
                return result;
            }
            if (destination.exists()) {
                result = result && destination.isDirectory();
            } else {
                result = result && destination.mkdirs();
            }
            File[] children = source.listFiles();
            for (File element : children) {
                String inName = element.getName();
                String outName;
                if (element.isDirectory()) {
                    outName = inName;
                } else {
                    outName = inName.substring(0, inName.lastIndexOf('.') + 1)
                            + m_outExt;
                }
                result = result && convert(new File(source, inName),
                                           new File(destination, outName));
            }
            return result;
        } else {
            try {
                if (!source.getName().endsWith("." + m_inExt)) {
                    return result;
                }
                InputStream in = new FileInputStream(source);
                if (!destination.getParentFile().exists()) {
                    destination.getParentFile().mkdirs();
                }
                OutputStream out = new FileOutputStream(destination);
                result = result && convert(in, out);
                out.close();
                in.close();
                return result;
            } catch (IOException e) {
                return false;
            }
        }
    }
279293
public static boolean execute(
    final File source, final File destination, boolean renameEmptyFiles) {
    if (renameEmptyFiles || (source.length() > 0)) {
      return source.renameTo(destination);
    }

    return source.delete();
  }
536586
public function copy(string $source, string $destination) : bool
    {
        $status = @copy($source, $destination);

        if (false === $status) {
            throw new FileException('Cannot copy source to destination.');
        }

        return $status;
    }
1009954
private Class<?> defineStructure(Field destination, Field source){
		
		Class<?> destinationClass = destination.getType();
		Class<?> sourceClass = source.getType();
		
		Class<?> result = null;
		
		// if destination is an interface
		if(destinationClass.isInterface())
			// if source is an interface
			if(sourceClass.isInterface())
					// retrieves the implementation of the destination interface
					result = (Class<?>) implementationClass.get(destinationClass.getName());
			// if source is an implementation	
			else{
				// retrieves source interface
				Class<?> sourceInterface = sourceClass.getInterfaces()[0];
				// if the destination and source interfaces are equal
				if(destinationClass.equals(sourceInterface))
					// assigns implementation to destination
					result = sourceClass;
				// if they are different
				else
					// destination gets the implementation of his interface
					result = (Class<?>) implementationClass.get(destinationClass.getName());
			}
		// if destination is an implementation
		else
			result = destinationClass;
		
		return result;
	}
580285
private boolean existsStrongerInColumn(INode source, INode target) {
        boolean result = false;

        char current = defautlMappings.getRelation(source, target);

        //compare with the other relations in the column
        for (INode i : defautlMappings.getSourceContext().getNodesList()) {
            if (i != source && defautlMappings.getRelation(i, target) != IMappingElement.IDK
                    && isPrecedent(defautlMappings.getRelation(i, target), current)) {
                result = true;
                break;
            }
        }

        return result;
    }
679761
public void addUsedConverter(IConverter converter, Object sourceObject,
			TypeReference<?> destinationType) {
		UsedConverter usedConverter = new UsedConverter(converter,
				sourceObject == null ? null : sourceObject.getClass(),
				destinationType);
		if (!usedConvertersSet.contains(usedConverter)) {
			usedConvertersSet.add(usedConverter);
			usedConvertersList.add(usedConverter);
		}
	}
506627
public boolean hasConversion(String type) {
		if ((isImplicitSarlTypes() && type.startsWith(IMPLICIT_PACKAGE))
			|| isImplicitJvmTypes()) {
			return true;
		}
		if (this.mapping == null) {
			this.mapping = initMapping();
		}
		return this.mapping.containsKey(type);
	}