protected function processInternal($object) {
		if (is_scalar($object)) {
			return $object;
		} elseif (is_array($object)) {
			return $this->processCollectionType($object, array_keys($object));
		} elseif ($object instanceof \DateTime) {
			return $object->format(DateTimeConverter::DEFAULT_DATE_FORMAT);
		} elseif (is_object($object) && ($object instanceof ArrayCollection)) {
			$arrayRepresentation = $object->toArray();
			return $this->processCollectionType($arrayRepresentation, array_keys($arrayRepresentation));
		} elseif ($object instanceof DataTransferInterface) {
			if (!$this->cacheTagService) {
				$content = $this->processCollectionType($object, $object->getPropertyNamesToBeApiExposed());
			} else {
				$this->cacheTagService->openEnvironment();
				$this->cacheTagService->addEnvironmentCacheTag($object);
				$identifier = md5($this->cacheTagService->createCacheIdentifier([$this->metaDataProcessorGroup, $object]));

				if (!$this->cache->has($identifier)) {
					$content = $this->processCollectionType($object, $object->getPropertyNamesToBeApiExposed());
					$this->cache->set($identifier, $content, $this->cacheTagService->getEnvironmentTags());
				} else {
					$content = $this->cache->get($identifier);
				}
				$this->cacheTagService->closeEnvironment();
			}
			return $content;
		} elseif ($object instanceof UriPointer) {
			return $this->processUriPointer($object);
		} elseif ($object instanceof Resource) {
			return $this->resourceManager->getPublicPersistentResourceUri($object);
		}
	}
protected function processInternal($object) {
		if (is_scalar($object)) {
			return $object;
		} elseif (is_array($object)) {
			return $this->processCollectionType($object, array_keys($object));
		} elseif ($object instanceof \DateTime) {
			return $object->format(DateTimeConverter::DEFAULT_DATE_FORMAT);
		} elseif (is_object($object) && ($object instanceof ArrayCollection)) {
			$arrayRepresentation = $object->toArray();
			return $this->processCollectionType($arrayRepresentation, array_keys($arrayRepresentation));
		} elseif ($object instanceof DataTransferInterface) {
			if (!$this->cacheTagService) {
				$content = $this->processCollectionType($object, $object->getPropertyNamesToBeApiExposed());
			} else {
				$this->cacheTagService->openEnvironment();
				$this->cacheTagService->addEnvironmentCacheTag($object);
				$identifier = md5($this->cacheTagService->createCacheIdentifier([$this->metaDataProcessorGroup, $object]));

				if (!$this->cache->has($identifier)) {
					$content = $this->processCollectionType($object, $object->getPropertyNamesToBeApiExposed());
					$this->cache->set($identifier, $content, $this->cacheTagService->getEnvironmentTags());
				} else {
					$content = $this->cache->get($identifier);
				}
				$this->cacheTagService->closeEnvironment();
			}
			return $content;
		} elseif ($object instanceof UriPointer) {
			return $this->processUriPointer($object);
		} elseif ($object instanceof Resource) {
			return $this->resourceManager->getPublicPersistentResourceUri($object);
		}
	}
protected function processInternal ( $ object ) { if ( is_scalar ( $ object ) ) { return $ object ; } elseif ( is_array ( $ object ) ) { return $ this -> processCollectionType ( $ object , array_keys ( $ object ) ) ; } elseif ( $ object instanceof \ DateTime ) { return $ object -> format ( DateTimeConverter :: DEFAULT_DATE_FORMAT ) ; } elseif ( is_object ( $ object ) && ( $ object instanceof ArrayCollection ) ) { $ arrayRepresentation = $ object -> toArray ( ) ; return $ this -> processCollectionType ( $ arrayRepresentation , array_keys ( $ arrayRepresentation ) ) ; } elseif ( $ object instanceof DataTransferInterface ) { if ( ! $ this -> cacheTagService ) { $ content = $ this -> processCollectionType ( $ object , $ object -> getPropertyNamesToBeApiExposed ( ) ) ; } else { $ this -> cacheTagService -> openEnvironment ( ) ; $ this -> cacheTagService -> addEnvironmentCacheTag ( $ object ) ; $ identifier = md5 ( $ this -> cacheTagService -> createCacheIdentifier ( [ $ this -> metaDataProcessorGroup , $ object ] ) ) ; if ( ! $ this -> cache -> has ( $ identifier ) ) { $ content = $ this -> processCollectionType ( $ object , $ object -> getPropertyNamesToBeApiExposed ( ) ) ; $ this -> cache -> set ( $ identifier , $ content , $ this -> cacheTagService -> getEnvironmentTags ( ) ) ; } else { $ content = $ this -> cache -> get ( $ identifier ) ; } $ this -> cacheTagService -> closeEnvironment ( ) ; } return $ content ; } elseif ( $ object instanceof UriPointer ) { return $ this -> processUriPointer ( $ object ) ; } elseif ( $ object instanceof Resource ) { return $ this -> resourceManager -> getPublicPersistentResourceUri ( $ object ) ; } }
Dispatcher which kind of processing has to be done.

@param mixed $object
@return mixed
Dispatcher which kind of processing has to be done .