Skip to content
This repository has been archived by the owner on Oct 23, 2022. It is now read-only.

Commit

Permalink
update glasscat documentation
Browse files Browse the repository at this point in the history
1. update docs to reflect renaming of GlassCat.glasses ->
   GlassCat.glassnames
2. restore docstring for isair()

fixes #81
  • Loading branch information
alfredclwong committed Apr 7, 2021
1 parent 88a22f5 commit ec7d3c1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion docs/src/glasscat.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ OpticSim.GlassCat.modelglass

```@docs
OpticSim.GlassCat.glasscatalogs
OpticSim.GlassCat.glasses
OpticSim.GlassCat.glassnames
OpticSim.GlassCat.info
OpticSim.GlassCat.findglass
OpticSim.GlassCat.isair
Expand Down
5 changes: 5 additions & 0 deletions src/GlassCat/Air.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ Base.show(io::IO, ::AirType) = print(io, "Air")
glassid(::AirType) = GlassID(AIR, 0)
glassname(::AirType) = "GlassCat.Air"

"""
isair(a) -> Bool
Tests if a is Air.
"""
isair(::AirType) = true
isair(::AbstractGlass) = false
isair(a::GlassID) = a.type === AIR
Expand Down

0 comments on commit ec7d3c1

Please sign in to comment.