code: def in_memory(self, value):
          
  
          self_class = self.__class__
          memory = Annotation.__ANNOTATIONS_IN_MEMORY__
  
          if value:
              annotations_memory = memory.setdefault(self_class, set())
              annotations_memory.add(self)
  
          else:
              if self_class in memory:
                  annotations_memory = memory[self_class]
                  while self in annotations_memory:
                      annotations_memory.remove(self)
                  if not annotations_memory:
                      del memory[self_class]
docs: Add or remove self from global memory.
  
          :param bool value: if True(False) ensure self is(is not) in memory.