docs: @Override
      public ComponentType detach() {
          synchronized (this) {
              if (parent != null) {
                  ComponentVertex oldParent = parent;
                  synchronized (tree) {
                      if (!tree.isStarted()) {
                          throw new IllegalStateException(
                              "Components may not be detached from a tree before"
                                  + " a Start event has been fired on it.");
                      }
                      synchronized (oldParent) {
                          parent.children.remove(this);
                          parent.tree.clearHandlerCache();
                          parent = null;
                      }
                      ComponentTree newTree = new ComponentTree(this);
                      newTree.setEventPipeline(new FeedBackPipelineFilter(
                          new EventProcessor(newTree)));
                      setTree(newTree);
                  }
                  Detached evt = new Detached(component(), oldParent.component());
                  oldParent.fire(evt);
                  evt = new Detached(component(), oldParent.component());
                  fire(evt);
              }
              return component();
          }
      }