private function addResource(EasyRdf_Graph $graph, core_kernel_classes_Resource $resource)
    {
        foreach ($resource->getRdfTriples() as $triple) {
            $language = !empty($triple->lg) ? $triple->lg : null;
            if (common_Utils::isUri($triple->object)) {
                if ($triple->predicate !== OntologyRdf::RDF_TYPE && strpos($triple->object, LOCAL_NAMESPACE) !== false) {
                    continue;
                }
                $graph->add($triple->subject, $triple->predicate, $triple->object);
            } else {
                if ($this->isSerializedFile($triple->object)) {
                    continue;
                }
                $graph->addLiteral($triple->subject, $triple->predicate, $triple->object, $language);
            }
        }
    }