org-netbeans-modules-autoupdate-services

16:39:49.941 INFO  jd.cli.Main - Decompiling org-netbeans-modules-autoupdate-services.jar
package org.netbeans.api.autoupdate;

class InstallSupport$1 {}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.InstallSupport.1
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

public final class InstallSupport$Installer {}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.InstallSupport.Installer
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

public final class InstallSupport$Validator {}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.InstallSupport.Validator
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import org.netbeans.api.progress.ProgressHandle;
import org.netbeans.modules.autoupdate.services.InstallSupportImpl;

public final class InstallSupport
{
  private OperationContainer<InstallSupport> container;
  private InstallSupportImpl impl;
  
  InstallSupport()
  {
    impl = new InstallSupportImpl(this);
  }
  
  public Validator doDownload(ProgressHandle paramProgressHandle, boolean paramBoolean)
    throws OperationException
  {
    if (impl.doDownload(paramProgressHandle, paramBoolean)) {
      return new Validator(null);
    }
    return null;
  }
  
  public Installer doValidate(Validator paramValidator, ProgressHandle paramProgressHandle)
    throws OperationException
  {
    if (impl.doValidate(paramValidator, paramProgressHandle)) {
      return new Installer(null);
    }
    return null;
  }
  
  public OperationSupport.Restarter doInstall(Installer paramInstaller, ProgressHandle paramProgressHandle)
    throws OperationException
  {
    Boolean localBoolean = impl.doInstall(paramInstaller, paramProgressHandle);
    if ((localBoolean == null) || (!localBoolean.booleanValue())) {
      return null;
    }
    return new OperationSupport.Restarter();
  }
  
  public void doCancel()
    throws OperationException
  {
    impl.doCancel();
  }
  
  public void doRestart(OperationSupport.Restarter paramRestarter, ProgressHandle paramProgressHandle)
    throws OperationException
  {
    impl.doRestart(paramRestarter, paramProgressHandle);
  }
  
  public void doRestartLater(OperationSupport.Restarter paramRestarter)
  {
    impl.doRestartLater(paramRestarter);
  }
  
  public String getCertificate(Installer paramInstaller, UpdateElement paramUpdateElement)
  {
    return impl.getCertificate(paramInstaller, paramUpdateElement);
  }
  
  public boolean isTrusted(Installer paramInstaller, UpdateElement paramUpdateElement)
  {
    return impl.isTrusted(paramInstaller, paramUpdateElement);
  }
  
  public boolean isSigned(Installer paramInstaller, UpdateElement paramUpdateElement)
  {
    return impl.isSigned(paramInstaller, paramUpdateElement);
  }
  
  public OperationContainer<InstallSupport> getContainer()
  {
    return container;
  }
  
  void setContainer(OperationContainer<InstallSupport> paramOperationContainer)
  {
    container = paramOperationContainer;
  }
  
  public static final class Installer {}
  
  public static final class Validator {}
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.InstallSupport
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import java.util.LinkedHashSet;
import java.util.Set;
import org.netbeans.modules.autoupdate.services.OperationContainerImpl;
import org.netbeans.modules.autoupdate.services.OperationContainerImpl.OperationInfoImpl;

public final class OperationContainer$OperationInfo<Support>
{
  OperationContainerImpl<Support>.OperationInfoImpl<Support> impl;
  
  OperationContainer$OperationInfo(OperationContainerImpl<Support>.OperationInfoImpl<Support> paramOperationContainerImpl)
  {
    impl = paramOperationContainerImpl;
  }
  
  public UpdateElement getUpdateElement()
  {
    return impl.getUpdateElement();
  }
  
  public UpdateUnit getUpdateUnit()
  {
    return impl.getUpdateUnit();
  }
  
  public Set<UpdateElement> getRequiredElements()
  {
    return new LinkedHashSet(impl.getRequiredElements());
  }
  
  public Set<String> getBrokenDependencies()
  {
    return impl.getBrokenDependencies();
  }
  
  public String toString()
  {
    return "OperationInfo: " + impl.getUpdateElement().toString();
  }
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.OperationContainer.OperationInfo
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import java.util.Collection;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
import org.netbeans.modules.autoupdate.services.OperationContainerImpl;
import org.netbeans.modules.autoupdate.services.OperationContainerImpl.OperationInfoImpl;

public final class OperationContainer<Support>
{
  OperationContainerImpl<Support> impl;
  private Support support;
  
  public static OperationContainer<InstallSupport> createForInstall()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForInstall(), new InstallSupport());
    
    ((InstallSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<InstallSupport> createForInternalUpdate()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForInternalUpdate(), new InstallSupport());
    
    ((InstallSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<OperationSupport> createForDirectInstall()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForDirectInstall(), new OperationSupport());
    
    ((OperationSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<InstallSupport> createForUpdate()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForUpdate(), new InstallSupport());
    
    ((InstallSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<OperationSupport> createForDirectUpdate()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForDirectUpdate(), new OperationSupport());
    
    ((OperationSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<OperationSupport> createForUninstall()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForUninstall(), new OperationSupport());
    
    ((OperationSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<OperationSupport> createForDirectUninstall()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForDirectUninstall(), new OperationSupport());
    
    ((OperationSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<OperationSupport> createForEnable()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForEnable(), new OperationSupport());
    
    ((OperationSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<OperationSupport> createForDisable()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForDisable(), new OperationSupport());
    
    ((OperationSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<OperationSupport> createForDirectDisable()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForDirectDisable(), new OperationSupport());
    
    ((OperationSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<OperationSupport> createForCustomInstallComponent()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForInstallNativeComponent(), new OperationSupport());
    
    ((OperationSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public static OperationContainer<OperationSupport> createForCustomUninstallComponent()
  {
    OperationContainer localOperationContainer = new OperationContainer(OperationContainerImpl.createForUninstallNativeComponent(), new OperationSupport());
    
    ((OperationSupport)localOperationContainer.getSupportInner()).setContainer(localOperationContainer);
    return localOperationContainer;
  }
  
  public Support getSupport()
  {
    if (upToDate) {
      return (Support)support;
    }
    if ((listAll().size() > 0) && (listInvalid().size() == 0))
    {
      upToDate = true;
      return (Support)support;
    }
    return null;
  }
  
  Support getSupportInner()
  {
    return (Support)support;
  }
  
  public boolean canBeAdded(UpdateUnit paramUpdateUnit, UpdateElement paramUpdateElement)
  {
    return impl.isValid(paramUpdateUnit, paramUpdateElement);
  }
  
  public void add(Collection<UpdateElement> paramCollection)
  {
    if (paramCollection == null) {
      throw new IllegalArgumentException("Cannot add null value.");
    }
    for (UpdateElement localUpdateElement : paramCollection) {
      add(localUpdateElement);
    }
  }
  
  public void add(Map<UpdateUnit, UpdateElement> paramMap)
  {
    if (paramMap == null) {
      throw new IllegalArgumentException("Cannot add null value.");
    }
    for (Map.Entry localEntry : paramMap.entrySet()) {
      add((UpdateUnit)localEntry.getKey(), (UpdateElement)localEntry.getValue());
    }
  }
  
  public OperationInfo<Support> add(UpdateUnit paramUpdateUnit, UpdateElement paramUpdateElement)
  {
    upToDate = false;
    return impl.add(paramUpdateUnit, paramUpdateElement);
  }
  
  public OperationInfo<Support> add(UpdateElement paramUpdateElement)
  {
    upToDate = false;
    UpdateUnit localUpdateUnit = paramUpdateElement.getUpdateUnit();
    return add(localUpdateUnit, paramUpdateElement);
  }
  
  public void remove(Collection<UpdateElement> paramCollection)
  {
    if (paramCollection == null) {
      throw new IllegalArgumentException("Cannot add null value.");
    }
    for (UpdateElement localUpdateElement : paramCollection) {
      remove(localUpdateElement);
    }
  }
  
  public boolean remove(UpdateElement paramUpdateElement)
  {
    upToDate = false;
    return impl.remove(paramUpdateElement);
  }
  
  public boolean contains(UpdateElement paramUpdateElement)
  {
    return impl.contains(paramUpdateElement);
  }
  
  public List<OperationInfo<Support>> listAll()
  {
    return impl.listAllWithPossibleEager();
  }
  
  public List<OperationInfo<Support>> listInvalid()
  {
    return impl.listInvalid();
  }
  
  public void remove(OperationInfo<Support> paramOperationInfo)
  {
    upToDate = false;
    impl.remove(paramOperationInfo);
  }
  
  public void removeAll()
  {
    upToDate = false;
    impl.removeAll();
  }
  
  public static final class OperationInfo<Support>
  {
    OperationContainerImpl<Support>.OperationInfoImpl<Support> impl;
    
    OperationInfo(OperationContainerImpl<Support>.OperationInfoImpl<Support> paramOperationContainerImpl)
    {
      impl = paramOperationContainerImpl;
    }
    
    public UpdateElement getUpdateElement()
    {
      return impl.getUpdateElement();
    }
    
    public UpdateUnit getUpdateUnit()
    {
      return impl.getUpdateUnit();
    }
    
    public Set<UpdateElement> getRequiredElements()
    {
      return new LinkedHashSet(impl.getRequiredElements());
    }
    
    public Set<String> getBrokenDependencies()
    {
      return impl.getBrokenDependencies();
    }
    
    public String toString()
    {
      return "OperationInfo: " + impl.getUpdateElement().toString();
    }
  }
  
  private OperationContainer(OperationContainerImpl<Support> paramOperationContainerImpl, Support paramSupport)
  {
    impl = paramOperationContainerImpl;
    support = paramSupport;
    paramOperationContainerImpl.setOperationContainer(this);
  }
  
  private boolean upToDate = false;
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.OperationContainer
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

public enum OperationException$ERROR_TYPE
{
  PROXY,  INSTALLER,  INSTALL,  ENABLE,  UNINSTALL;
  
  private OperationException$ERROR_TYPE() {}
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.OperationException.ERROR_TYPE
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

public final class OperationException
  extends Exception
{
  private ERROR_TYPE error;
  private String msg;
  
  public static enum ERROR_TYPE
  {
    PROXY,  INSTALLER,  INSTALL,  ENABLE,  UNINSTALL;
    
    private ERROR_TYPE() {}
  }
  
  public OperationException(ERROR_TYPE paramERROR_TYPE)
  {
    error = paramERROR_TYPE;
    msg = paramERROR_TYPE.toString();
  }
  
  public OperationException(ERROR_TYPE paramERROR_TYPE, Exception paramException)
  {
    super(paramException);
    error = paramERROR_TYPE;
    msg = paramException.getLocalizedMessage();
  }
  
  public OperationException(ERROR_TYPE paramERROR_TYPE, String paramString)
  {
    super(paramString);
    error = paramERROR_TYPE;
    msg = paramString;
  }
  
  public String getLocalizedMessage()
  {
    return msg;
  }
  
  public ERROR_TYPE getErrorType()
  {
    return error;
  }
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.OperationException
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

class OperationSupport$1 {}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.OperationSupport.1
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

public final class OperationSupport$Restarter {}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.OperationSupport.Restarter
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import org.netbeans.api.progress.ProgressHandle;
import org.netbeans.modules.autoupdate.services.OperationContainerImpl;
import org.netbeans.modules.autoupdate.services.OperationContainerImpl.OperationType;
import org.netbeans.modules.autoupdate.services.OperationSupportImpl;

public final class OperationSupport
{
  private OperationContainer<OperationSupport> container;
  
  public Restarter doOperation(ProgressHandle paramProgressHandle)
    throws OperationException
  {
    Boolean localBoolean = getImpl(container.impl.getType()).doOperation(paramProgressHandle, container);
    if ((localBoolean == null) || (!localBoolean.booleanValue())) {
      return null;
    }
    return new Restarter();
  }
  
  public void doCancel()
    throws OperationException
  {
    getImpl(container.impl.getType()).doCancel();
  }
  
  public void doRestart(Restarter paramRestarter, ProgressHandle paramProgressHandle)
    throws OperationException
  {
    getImpl(container.impl.getType()).doRestart(paramRestarter, paramProgressHandle);
  }
  
  public void doRestartLater(Restarter paramRestarter)
  {
    getImpl(container.impl.getType()).doRestartLater(paramRestarter);
  }
  
  void setContainer(OperationContainer<OperationSupport> paramOperationContainer)
  {
    container = paramOperationContainer;
  }
  
  private static OperationSupportImpl getImpl(OperationContainerImpl.OperationType paramOperationType)
  {
    assert (paramOperationType != null) : "OperationContainerImpl.OperationType cannot be null.";
    OperationSupportImpl localOperationSupportImpl = null;
    switch (paramOperationType)
    {
    case INSTALL: 
      localOperationSupportImpl = OperationSupportImpl.forInstall();
      break;
    case UNINSTALL: 
      localOperationSupportImpl = OperationSupportImpl.forUninstall();
      break;
    case DIRECT_UNINSTALL: 
      localOperationSupportImpl = OperationSupportImpl.forDirectUninstall();
      break;
    case UPDATE: 
      localOperationSupportImpl = OperationSupportImpl.forUpdate();
      break;
    case ENABLE: 
      localOperationSupportImpl = OperationSupportImpl.forEnable();
      break;
    case DISABLE: 
      localOperationSupportImpl = OperationSupportImpl.forDisable();
      break;
    case DIRECT_DISABLE: 
      localOperationSupportImpl = OperationSupportImpl.forDirectDisable();
      break;
    case CUSTOM_INSTALL: 
      localOperationSupportImpl = OperationSupportImpl.forCustomInstall();
      break;
    case CUSTOM_UNINSTALL: 
      localOperationSupportImpl = OperationSupportImpl.forCustomUninstall();
      break;
    case INTERNAL_UPDATE: 
      localOperationSupportImpl = OperationSupportImpl.forInternalUpdate();
      break;
    default: 
      if (!$assertionsDisabled) {
        throw new AssertionError("Unknown OperationSupport for type " + paramOperationType);
      }
      break;
    }
    assert (localOperationSupportImpl != null) : ("OperationSupportImpl cannot be null for operation " + paramOperationType);
    return localOperationSupportImpl;
  }
  
  public static final class Restarter {}
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.OperationSupport
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import java.io.File;
import java.io.IOException;
import org.netbeans.modules.autoupdate.services.OperationContainerImpl;
import org.netbeans.modules.autoupdate.services.OperationContainerImpl.OperationInfoImpl;
import org.netbeans.modules.autoupdate.services.Trampoline;
import org.netbeans.modules.autoupdate.services.UpdateElementImpl;
import org.netbeans.modules.autoupdate.services.UpdateUnitImpl;
import org.netbeans.modules.autoupdate.services.UpdateUnitProviderImpl;
import org.netbeans.modules.autoupdate.updateprovider.UpdateItemImpl;
import org.netbeans.spi.autoupdate.AutoupdateClusterCreator;
import org.netbeans.spi.autoupdate.UpdateItem;

final class TrampolineAPI
  extends Trampoline
{
  protected UpdateUnit createUpdateUnit(UpdateUnitImpl paramUpdateUnitImpl)
  {
    UpdateUnit localUpdateUnit = new UpdateUnit(paramUpdateUnitImpl);
    paramUpdateUnitImpl.setUpdateUnit(localUpdateUnit);
    return localUpdateUnit;
  }
  
  protected UpdateUnitImpl impl(UpdateUnit paramUpdateUnit)
  {
    return impl;
  }
  
  protected UpdateElement createUpdateElement(UpdateElementImpl paramUpdateElementImpl)
  {
    UpdateElement localUpdateElement = new UpdateElement(paramUpdateElementImpl);
    paramUpdateElementImpl.setUpdateElement(localUpdateElement);
    return localUpdateElement;
  }
  
  protected UpdateElementImpl impl(UpdateElement paramUpdateElement)
  {
    return impl;
  }
  
  public UpdateItemImpl impl(UpdateItem paramUpdateItem)
  {
    throw new UnsupportedOperationException("Not supported yet.");
  }
  
  protected UpdateItem createUpdateItem(UpdateItemImpl paramUpdateItemImpl)
  {
    throw new UnsupportedOperationException("Not supported yet.");
  }
  
  protected OperationContainerImpl impl(OperationContainer paramOperationContainer)
  {
    return impl;
  }
  
  protected UpdateUnitProvider createUpdateUnitProvider(UpdateUnitProviderImpl paramUpdateUnitProviderImpl)
  {
    return new UpdateUnitProvider(paramUpdateUnitProviderImpl);
  }
  
  public UpdateUnitProviderImpl impl(UpdateUnitProvider paramUpdateUnitProvider)
  {
    return impl;
  }
  
  protected OperationContainerImpl.OperationInfoImpl impl(OperationContainer.OperationInfo paramOperationInfo)
  {
    return impl;
  }
  
  protected OperationContainer.OperationInfo createOperationInfo(OperationContainerImpl.OperationInfoImpl paramOperationInfoImpl)
  {
    return new OperationContainer.OperationInfo(paramOperationInfoImpl);
  }
  
  protected File findCluster(String paramString, AutoupdateClusterCreator paramAutoupdateClusterCreator)
  {
    throw new UnsupportedOperationException("Not supported yet.");
  }
  
  protected File[] registerCluster(String paramString, File paramFile, AutoupdateClusterCreator paramAutoupdateClusterCreator)
    throws IOException
  {
    throw new UnsupportedOperationException("Not supported yet.");
  }
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.TrampolineAPI
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import java.util.List;
import org.netbeans.modules.autoupdate.services.UpdateElementImpl;
import org.openide.modules.SpecificationVersion;

public final class UpdateElement
{
  final UpdateElementImpl impl;
  
  UpdateElement(UpdateElementImpl paramUpdateElementImpl)
  {
    if (paramUpdateElementImpl == null) {
      throw new IllegalArgumentException("UpdateElementImpl cannot be null while creating UpdateElement.");
    }
    impl = paramUpdateElementImpl;
  }
  
  public UpdateUnit getUpdateUnit()
  {
    assert (impl.getUpdateUnit() != null) : ("UpdateUnit for UpdateElement " + this + " is not null.");
    return impl.getUpdateUnit();
  }
  
  public String getCodeName()
  {
    return impl.getCodeName();
  }
  
  public String getDisplayName()
  {
    return impl.getDisplayName();
  }
  
  public String getSpecificationVersion()
  {
    return impl.getSpecificationVersion() == null ? null : impl.getSpecificationVersion().toString();
  }
  
  public boolean isEnabled()
  {
    return impl.isEnabled();
  }
  
  public String getDescription()
  {
    return impl.getDescription();
  }
  
  public String getNotification()
  {
    return impl.getNotification();
  }
  
  public String getSource()
  {
    return impl.getSource();
  }
  
  public UpdateUnitProvider.CATEGORY getSourceCategory()
  {
    UpdateUnitProvider localUpdateUnitProvider = getUpdateUnitProvider();
    return localUpdateUnitProvider != null ? localUpdateUnitProvider.getCategory() : UpdateUnitProvider.CATEGORY.COMMUNITY;
  }
  
  private UpdateUnitProvider getUpdateUnitProvider()
  {
    String str = getSource();
    Object localObject = null;
    List localList = UpdateUnitProviderFactory.getDefault().getUpdateUnitProviders(false);
    for (UpdateUnitProvider localUpdateUnitProvider : localList) {
      if ((str != null) && (str.equals(localUpdateUnitProvider.getDisplayName()))) {
        localObject = localUpdateUnitProvider;
      }
    }
    return (UpdateUnitProvider)localObject;
  }
  
  public String getAuthor()
  {
    return impl.getAuthor();
  }
  
  public String getHomepage()
  {
    return impl.getHomepage();
  }
  
  public int getDownloadSize()
  {
    return impl.getDownloadSize();
  }
  
  public String getCategory()
  {
    return impl.getCategory();
  }
  
  public String getDate()
  {
    return impl.getDate();
  }
  
  public String getLicence()
  {
    return impl.getLicence();
  }
  
  public boolean equals(Object paramObject)
  {
    if (paramObject == null) {
      return false;
    }
    if (getClass() != paramObject.getClass()) {
      return false;
    }
    UpdateElement localUpdateElement = (UpdateElement)paramObject;
    if ((impl != impl) && ((impl == null) || (!impl.equals(impl)))) {
      return false;
    }
    return true;
  }
  
  public int hashCode()
  {
    int i = 3;
    
    i = 53 * i + (impl != null ? impl.hashCode() : 0);
    
    return i;
  }
  
  public String toString()
  {
    return impl.getDisplayName() + "[" + impl.getCodeName() + "/" + impl.getSpecificationVersion() + "]";
  }
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.UpdateElement
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

public enum UpdateManager$TYPE
{
  MODULE,  FEATURE,  STANDALONE_MODULE,  KIT_MODULE,  CUSTOM_HANDLED_COMPONENT,  LOCALIZATION;
  
  private UpdateManager$TYPE() {}
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.UpdateManager.TYPE
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import java.util.List;
import org.netbeans.modules.autoupdate.services.UpdateManagerImpl;

public final class UpdateManager
{
  public static enum TYPE
  {
    MODULE,  FEATURE,  STANDALONE_MODULE,  KIT_MODULE,  CUSTOM_HANDLED_COMPONENT,  LOCALIZATION;
    
    private TYPE() {}
  }
  
  private static UpdateManager mgr = null;
  
  public static final UpdateManager getDefault()
  {
    if (mgr == null) {
      mgr = new UpdateManager();
    }
    return mgr;
  }
  
  public List<UpdateUnit> getUpdateUnits()
  {
    return getImpl().getUpdateUnits();
  }
  
  public List<UpdateUnit> getUpdateUnits(TYPE... paramVarArgs)
  {
    return getImpl().getUpdateUnits(paramVarArgs);
  }
  
  private static UpdateManagerImpl getImpl()
  {
    return UpdateManagerImpl.getInstance();
  }
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.UpdateManager
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import java.util.List;
import org.netbeans.modules.autoupdate.services.UpdateUnitImpl;

public final class UpdateUnit
{
  final UpdateUnitImpl impl;
  
  static
  {
    org.netbeans.modules.autoupdate.services.Trampoline.API = new TrampolineAPI();
  }
  
  UpdateUnit(UpdateUnitImpl paramUpdateUnitImpl)
  {
    impl = paramUpdateUnitImpl;
  }
  
  public String getCodeName()
  {
    return impl.getCodeName();
  }
  
  public UpdateElement getInstalled()
  {
    return impl.getInstalled();
  }
  
  public List<UpdateElement> getAvailableUpdates()
  {
    return impl.getAvailableUpdates();
  }
  
  public UpdateElement getBackup()
  {
    return impl.getBackup();
  }
  
  public UpdateElement getInstalledLocalization()
  {
    return impl.getInstalledLocalization();
  }
  
  public List<UpdateElement> getAvailableLocalizations()
  {
    return impl.getAvailableLocalizations();
  }
  
  public UpdateManager.TYPE getType()
  {
    return impl.getType();
  }
  
  public boolean isPending()
  {
    return impl.isPending();
  }
  
  public boolean equals(Object paramObject)
  {
    if (paramObject == null) {
      return false;
    }
    if (getClass() != paramObject.getClass()) {
      return false;
    }
    UpdateUnit localUpdateUnit = (UpdateUnit)paramObject;
    if ((impl != impl) && ((impl == null) || (!impl.equals(impl)))) {
      return false;
    }
    return true;
  }
  
  public int hashCode()
  {
    int i = 5;
    
    i = 59 * i + (impl != null ? impl.hashCode() : 0);
    
    return i;
  }
  
  public String toString()
  {
    return impl.getCodeName();
  }
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.UpdateUnit
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

public enum UpdateUnitProvider$CATEGORY
{
  STANDARD,  COMMUNITY,  BETA;
  
  private UpdateUnitProvider$CATEGORY() {}
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.UpdateUnitProvider.CATEGORY
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import java.io.IOException;
import java.net.URL;
import java.util.List;
import org.netbeans.api.progress.ProgressHandle;
import org.netbeans.modules.autoupdate.services.UpdateUnitProviderImpl;

public final class UpdateUnitProvider
{
  UpdateUnitProviderImpl impl;
  
  public static enum CATEGORY
  {
    STANDARD,  COMMUNITY,  BETA;
    
    private CATEGORY() {}
  }
  
  UpdateUnitProvider(UpdateUnitProviderImpl paramUpdateUnitProviderImpl)
  {
    impl = paramUpdateUnitProviderImpl;
  }
  
  public String getName()
  {
    return impl.getName();
  }
  
  public String getDisplayName()
  {
    return impl.getDisplayName();
  }
  
  public void setDisplayName(String paramString)
  {
    impl.setDisplayName(paramString);
  }
  
  public String getDescription()
  {
    return impl.getDescription();
  }
  
  public CATEGORY getCategory()
  {
    return impl.getCategory();
  }
  
  public URL getProviderURL()
  {
    return impl.getProviderURL();
  }
  
  public void setProviderURL(URL paramURL)
  {
    impl.setProviderURL(paramURL);
  }
  
  public List<UpdateUnit> getUpdateUnits()
  {
    return impl.getUpdateUnits(new UpdateManager.TYPE[0]);
  }
  
  public List<UpdateUnit> getUpdateUnits(UpdateManager.TYPE... paramVarArgs)
  {
    return impl.getUpdateUnits(paramVarArgs);
  }
  
  public boolean refresh(ProgressHandle paramProgressHandle, boolean paramBoolean)
    throws IOException
  {
    return impl.refresh(paramProgressHandle, paramBoolean);
  }
  
  public boolean isEnabled()
  {
    return impl.isEnabled();
  }
  
  public void setEnable(boolean paramBoolean)
  {
    impl.setEnable(paramBoolean);
  }
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.UpdateUnitProvider
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.api.autoupdate;

import java.io.File;
import java.io.IOException;
import java.net.URL;
import java.util.List;
import org.netbeans.api.progress.ProgressHandle;
import org.netbeans.modules.autoupdate.services.UpdateUnitProviderImpl;

public final class UpdateUnitProviderFactory
{
  private static final UpdateUnitProviderFactory INSTANCE = new UpdateUnitProviderFactory();
  
  public static UpdateUnitProviderFactory getDefault()
  {
    return INSTANCE;
  }
  
  public List<UpdateUnitProvider> getUpdateUnitProviders(boolean paramBoolean)
  {
    return UpdateUnitProviderImpl.getUpdateUnitProviders(paramBoolean);
  }
  
  public UpdateUnitProvider create(String paramString1, String paramString2, URL paramURL, UpdateUnitProvider.CATEGORY paramCATEGORY)
  {
    return UpdateUnitProviderImpl.createUpdateUnitProvider(paramString1, paramString2, paramURL, paramCATEGORY);
  }
  
  public UpdateUnitProvider create(String paramString1, String paramString2, URL paramURL)
  {
    return UpdateUnitProviderImpl.createUpdateUnitProvider(paramString1, paramString2, paramURL, UpdateUnitProvider.CATEGORY.COMMUNITY);
  }
  
  public UpdateUnitProvider create(String paramString, File... paramVarArgs)
  {
    return UpdateUnitProviderImpl.createUpdateUnitProvider(paramString, paramVarArgs);
  }
  
  public void remove(UpdateUnitProvider paramUpdateUnitProvider)
  {
    UpdateUnitProviderImpl.remove(paramUpdateUnitProvider);
  }
  
  public void refreshProviders(ProgressHandle paramProgressHandle, boolean paramBoolean)
    throws IOException
  {
    UpdateUnitProviderImpl.refreshProviders(paramProgressHandle, paramBoolean);
  }
}

/* Location:
 * Qualified Name:     org.netbeans.api.autoupdate.UpdateUnitProviderFactory
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.modules.autoupdate.services;

import java.util.Date;
import java.util.logging.Level;
import java.util.logging.Logger;
import java.util.prefs.Preferences;
import org.openide.util.NbPreferences;

public class AutoupdateSettings
{
  private static final String PROP_OPEN_CONNECTION_TIMEOUT = "plugin.manager.connection.timeout";
  public static final int DEFAULT_OPEN_CONNECTION_TIMEOUT = 30000;
  private static final String PROP_LAST_CHECK = "lastCheckTime";
  private static final Logger err = Logger.getLogger(AutoupdateSettings.class.getName());
  
  public static void setLastCheck(Date paramDate)
  {
    err.log(Level.FINER, "Set the last check to " + paramDate);
    if (paramDate != null) {
      getPreferences().putLong("lastCheckTime", paramDate.getTime());
    } else {
      getPreferences().remove("lastCheckTime");
    }
  }
  
  public static void setLastCheck(String paramString, Date paramDate)
  {
    err.log(Level.FINER, "Set the last check to " + paramDate);
    if (paramDate != null) {
      getPreferences().putLong(paramString + "_" + "lastCheckTime", paramDate.getTime());
    } else {
      getPreferences().remove(paramString + "_" + "lastCheckTime");
    }
  }
  
  private static Preferences getPreferences()
  {
    return NbPreferences.root().node("/org/netbeans/modules/autoupdate");
  }
  
  public static int getOpenConnectionTimeout()
  {
    return getPreferences().getInt("plugin.manager.connection.timeout", 30000);
  }
}

/* Location:
 * Qualified Name:     org.netbeans.modules.autoupdate.services.AutoupdateSettings
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.modules.autoupdate.services;

public class DependencyAggregator$DependencyDecoratorKey
{
  private final String name;
  private final int type;
  private final int hashCode;
  
  public DependencyAggregator$DependencyDecoratorKey(String paramString, int paramInt1, int paramInt2)
  {
    name = paramString;
    type = paramInt1;
    hashCode = (0xBC7E3 ^ type ^ paramString.hashCode());
  }
  
  public boolean equals(Object paramObject)
  {
    if (paramObject.getClass() != DependencyDecoratorKey.class) {
      return false;
    }
    DependencyDecoratorKey localDependencyDecoratorKey = (DependencyDecoratorKey)paramObject;
    
    return (type == type) && (name.equals(name));
  }
  
  public int hashCode()
  {
    return hashCode;
  }
  
  public String toString()
  {
    StringBuffer localStringBuffer = new StringBuffer(100);
    localStringBuffer.append("Key[");
    if (type == 1) {
      localStringBuffer.append("module ");
    } else if (type == 2) {
      localStringBuffer.append("package ");
    } else if (type == 5) {
      localStringBuffer.append("requires ");
    } else if (type == 6) {
      localStringBuffer.append("needs ");
    } else if (type == 7) {
      localStringBuffer.append("recommends ");
    }
    localStringBuffer.append(name);
    
    localStringBuffer.append(']');
    
    return localStringBuffer.toString();
  }
}

/* Location:
 * Qualified Name:     org.netbeans.modules.autoupdate.services.DependencyAggregator.DependencyDecoratorKey
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.modules.autoupdate.services;

import java.util.Collection;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;
import java.util.concurrent.CopyOnWriteArraySet;
import org.netbeans.api.autoupdate.UpdateUnit;
import org.openide.modules.Dependency;
import org.openide.modules.ModuleInfo;

public class DependencyAggregator
{
  private static final Map<DependencyDecoratorKey, DependencyAggregator> key2dependency = new HashMap(11, 11.0F);
  private Collection<ModuleInfo> depending = new CopyOnWriteArraySet();
  private final DependencyDecoratorKey key;
  
  private DependencyAggregator(DependencyDecoratorKey paramDependencyDecoratorKey)
  {
    key = paramDependencyDecoratorKey;
  }
  
  public static DependencyAggregator getAggregator(Dependency paramDependency)
  {
    DependencyDecoratorKey localDependencyDecoratorKey = new DependencyDecoratorKey(paramDependency.getName(), paramDependency.getType(), paramDependency.getComparison());
    synchronized (key2dependency)
    {
      DependencyAggregator localDependencyAggregator = (DependencyAggregator)key2dependency.get(localDependencyDecoratorKey);
      if (localDependencyAggregator == null)
      {
        localDependencyAggregator = new DependencyAggregator(localDependencyDecoratorKey);
        key2dependency.put(localDependencyDecoratorKey, localDependencyAggregator);
      }
      return localDependencyAggregator;
    }
  }
  
  public int getType()
  {
    return key.type;
  }
  
  public String getName()
  {
    return key.name;
  }
  
  public boolean addDependee(ModuleInfo paramModuleInfo)
  {
    return depending.add(paramModuleInfo);
  }
  
  public Collection<ModuleInfo> getDependening()
  {
    return depending;
  }
  
  public String toString()
  {
    return "DependencyDecorator[" + key.toString() + "]";
  }
  
  public static UpdateUnit getRequested(Dependency paramDependency)
  {
    switch (paramDependency.getType())
    {
    case 1: 
      return UpdateManagerImpl.getInstance().getUpdateUnit(paramDependency.getName());
    case 5: 
    case 6: 
    case 7: 
      Collection localCollection = UpdateManagerImpl.getInstance().getInstalledProviders(paramDependency.getName());
      if (localCollection.isEmpty())
      {
        localObject = UpdateManagerImpl.getInstance().getAvailableProviders(paramDependency.getName());
        if (((Collection)localObject).isEmpty()) {
          return null;
        }
        ModuleInfo localModuleInfo = (ModuleInfo)((Collection)localObject).iterator().next();
        return UpdateManagerImpl.getInstance().getUpdateUnit(localModuleInfo.getCodeNameBase());
      }
      Object localObject = (ModuleInfo)localCollection.iterator().next();
      return UpdateManagerImpl.getInstance().getUpdateUnit(((ModuleInfo)localObject).getCodeNameBase());
    }
    return null;
  }
  
  public static class DependencyDecoratorKey
  {
    private final String name;
    private final int type;
    private final int hashCode;
    
    public DependencyDecoratorKey(String paramString, int paramInt1, int paramInt2)
    {
      name = paramString;
      type = paramInt1;
      hashCode = (0xBC7E3 ^ type ^ paramString.hashCode());
    }
    
    public boolean equals(Object paramObject)
    {
      if (paramObject.getClass() != DependencyDecoratorKey.class) {
        return false;
      }
      DependencyDecoratorKey localDependencyDecoratorKey = (DependencyDecoratorKey)paramObject;
      
      return (type == type) && (name.equals(name));
    }
    
    public int hashCode()
    {
      return hashCode;
    }
    
    public String toString()
    {
      StringBuffer localStringBuffer = new StringBuffer(100);
      localStringBuffer.append("Key[");
      if (type == 1) {
        localStringBuffer.append("module ");
      } else if (type == 2) {
        localStringBuffer.append("package ");
      } else if (type == 5) {
        localStringBuffer.append("requires ");
      } else if (type == 6) {
        localStringBuffer.append("needs ");
      } else if (type == 7) {
        localStringBuffer.append("recommends ");
      }
      localStringBuffer.append(name);
      
      localStringBuffer.append(']');
      
      return localStringBuffer.toString();
    }
  }
}

/* Location:
 * Qualified Name:     org.netbeans.modules.autoupdate.services.DependencyAggregator
 * Java Class Version: 6 (50.0)
 * JD-Core Version:    0.7.1
 */
package org.netbeans.modules.autoupdate.services;

import java.util.Collection;
import java.util.Collections;
import java.util.HashSet;
import java.util.Iterator;
import java.util.Set;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.netbeans.Util;
import org.openide.modules.Dependency;
import org.openide.modules.ModuleInfo;
import org.openide.modules.SpecificationVersion;

class DependencyChecker
{
  private static final Logger err = Logger.getLogger(DependencyChecker.class.getName());
  
  public static Set<Dependency> findBrokenDependencies(Set<Depende
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

Further reading...

For more information on Java 1.5 Tiger, you may find Java 1.5 Tiger, A developer's Notebook by D. Flanagan and B. McLaughlin from O'Reilly of interest.

New!JAR listings


Copyright 2006-2017. Infinite Loop Ltd