public function duplicate( core_kernel_classes_Resource $resource, $excludedProperties = array())
    {
        $returnValue = null;
    	$newUri = common_Utils::getNewUri();
    	$collection = $this->getRdfTriples($resource);
        
    	if ($collection->count() > 0) {
    		
    		$platform = $this->getPersistence()->getPlatForm();
            $user = $this->getServiceLocator()->get(SessionService::SERVICE_ID)->getCurrentUser()->getIdentifier();
            $valuesToInsert = [];
    		
    		foreach ($collection->getIterator() as $triple) {
    			if (!in_array($triple->predicate, $excludedProperties)) {
                    $valuesToInsert[] = [
                        'modelid' => $this->getNewTripleModelId(),
                        'subject' => $newUri,
                        'predicate'=> $triple->predicate,
                        'object' => ($triple->object == null) ? '' : $triple->object,
                        'l_language' => ($triple->lg == null) ? '' : $triple->lg,
                        'author' => $user,
                        'epoch' => $platform->getNowExpression()
                    ];
    			}
	    	}
	    	
        	if ($this->getPersistence()->insertMultiple('statements', $valuesToInsert)) {
        		$returnValue = new core_kernel_classes_Resource($newUri);
        	}
    	}
        
        return $returnValue;
    }