<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Get nodeRef from nodeID in Alfresco Forum</title>
    <link>https://connect.hyland.com/t5/alfresco-forum/get-noderef-from-nodeid/m-p/146400#M38770</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I think this should be a simple thing but I'm not finding any information to get a nodeRef from a nodeId.&lt;/P&gt;&lt;P&gt;Is there any way to do this through the Java api?&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Francisco Duarte&lt;/P&gt;</description>
    <pubDate>Fri, 21 Oct 2022 13:19:54 GMT</pubDate>
    <dc:creator>franciscoduarte</dc:creator>
    <dc:date>2022-10-21T13:19:54Z</dc:date>
    <item>
      <title>Get nodeRef from nodeID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/get-noderef-from-nodeid/m-p/146400#M38770</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I think this should be a simple thing but I'm not finding any information to get a nodeRef from a nodeId.&lt;/P&gt;&lt;P&gt;Is there any way to do this through the Java api?&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Francisco Duarte&lt;/P&gt;</description>
      <pubDate>Fri, 21 Oct 2022 13:19:54 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/get-noderef-from-nodeid/m-p/146400#M38770</guid>
      <dc:creator>franciscoduarte</dc:creator>
      <dc:date>2022-10-21T13:19:54Z</dc:date>
    </item>
    <item>
      <title>Re: Get nodeRef from nodeID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/get-noderef-from-nodeid/m-p/146401#M38771</link>
      <description>&lt;P&gt;The NodeRef includes information about the Store, that includes by default one protocol and one identifier.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/Alfresco/alfresco-data-model/blob/master/src/main/java/org/alfresco/service/cmr/repository/StoreRef.java#L39" target="_blank" rel="nofollow noopener noreferrer"&gt;https://github.com/Alfresco/alfresco-data-model/blob/master/src/main/java/org/alfresco/service/cmr/repository/StoreRef.java#L39&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Default stores are the Workspace(&lt;SPAN class="pl-smi"&gt;StoreRef&lt;/SPAN&gt; &lt;SPAN class="pl-c1"&gt;STORE_REF_WORKSPACE_SPACESSTORE&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN class="pl-k"&gt;new&lt;/SPAN&gt; &lt;SPAN class="pl-smi"&gt;StoreRef&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN class="pl-c1"&gt;PROTOCOL_WORKSPACE&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN class="pl-s"&gt;"SpacesStore"&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;) and the Archive (&lt;SPAN class="pl-smi"&gt;StoreRef&lt;/SPAN&gt; &lt;SPAN class="pl-c1"&gt;STORE_REF_ARCHIVE_SPACESSTORE&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN class="pl-k"&gt;new&lt;/SPAN&gt; &lt;SPAN class="pl-smi"&gt;StoreRef&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN class="pl-c1"&gt;PROTOCOL_ARCHIVE&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN class="pl-s"&gt;"SpacesStore"&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;).&lt;/P&gt;
&lt;P&gt;The nodeId (by itself) doesn't include information about the Store, so you need to add this information to build a NodeRef.&lt;/P&gt;
&lt;PRE&gt;NodeRef nodeRef = 
    new NodeRef(StoreRef.STORE_REF_WORKSPACE_SPACES_STORE, nodeId);&lt;/PRE&gt;</description>
      <pubDate>Mon, 24 Oct 2022 07:40:42 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/get-noderef-from-nodeid/m-p/146401#M38771</guid>
      <dc:creator>angelborroy</dc:creator>
      <dc:date>2022-10-24T07:40:42Z</dc:date>
    </item>
  </channel>
</rss>

