Class NoDensityMapException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.io.IOException
org.biojava.nbio.structure.io.density.NoDensityMapException
All Implemented Interfaces:
Serializable

public class NoDensityMapException extends IOException
Thrown when no enabled source could supply a density map for an entry.

This is a routine outcome rather than an error: not every entry has density. Structures deposited without structure factors have none at all (4HHB, for instance), and a cryo-EM entry has no X-ray maps by construction. The per-source reasons are kept so that a caller — particularly a user interface — can explain why rather than just reporting a failure.

Since:
7.3.0
Author:
Amr ALHOSSARY
See Also:
  • Constructor Details

    • NoDensityMapException

      public NoDensityMapException(PdbId pdbId, DensityMapKind kind, Map<DensityMapSource,String> attempts)
      Parameters:
      pdbId - the entry that was requested, may be null for a request made by EMDB identifier
      kind - the kind of map that was requested
      attempts - what happened at each source that was tried, in the order tried
  • Method Details

    • getPdbId

      public PdbId getPdbId()
      Returns:
      the entry that was requested, or null
    • getKind

      public DensityMapKind getKind()
      Returns:
      the kind of map that was requested
    • getAttempts

      public Map<DensityMapSource,String> getAttempts()
      What happened at each source, in the order they were tried. Suitable for building a human-readable explanation.
      Returns:
      an unmodifiable map from source to reason