When working with diagrams in visual environments like graphical diagram editors, diagrams have to be represented by an internal model. Graphs and hypergraphs are well-known concepts for such internal models . This paper shows how hypergraphs can be uniformly used for a wide range of different diagram types where hyperedges are used to represent diagram components as well as spatial relations between components. Using such an internal model requires a method for translating diagrams into their hypergraph model. Such a graphical scanning method is proposed in this paper. The scanner makes use of a specification of the diagram language. Since the scanner also considers how diagram components are embedded into their context, it is applicable to a wide range of diagram languages and their hypergraph models.