title: How to convert from a String to an NBTCompoundTag?
body: <p>I am writing some code for an Minecraft Forge module, where I need to save and restore a TileEntity definition to and from a String.</p>
  
  <p>To convert from  a TileEntity to a String, I can use:</p>
  
  <pre><code>NBTCompoundTag nbt = new NBTCompoundTag();
  TileEntity te = world.getTileEntity(x,y,z);
  te.writeToNBT(nbt);
  String nbtStr = nbt.toString();                         
  </code></pre>
  
  <p>However, to convert back from a String to a TileEntitiy, I am missing the reverse of the toString method (some sort of NBT parser).</p>
  
  <pre><code>String nbtStr;
  NBTTagCompound nbtTag = new NBTTagCompound();
  // this function does not exist
  // nbtTag.parseString(nbtStr);
  TileEntity te = TileEntity.createAndLoadEntity(nbtTag);
  world.setTileEntity(x,y,z,te);
  </code></pre>
  
  <p>I have searched through the various documentation, and am unable to find a function that can convert a String representation to a parsed NBTCompoundTag object.</p>
  
  <p>My question is, what is the method to parse in a string holding NBT?</p>