mirror of
				https://github.com/Theodor-Springmann-Stiftung/hamann-ausgabe-core.git
				synced 2025-10-31 02:05:33 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			28 lines
		
	
	
		
			582 B
		
	
	
	
		
			C#
		
	
	
	
	
	
			
		
		
	
	
			28 lines
		
	
	
		
			582 B
		
	
	
	
		
			C#
		
	
	
	
	
	
| namespace HaWeb.Controllers;
 | |
| 
 | |
| using HaWeb.CMIF;
 | |
| using HaWeb.FileHelpers;
 | |
| using Microsoft.AspNetCore.Mvc;
 | |
| 
 | |
| [ApiController]
 | |
| public class CMIFController : Controller {
 | |
| 
 | |
|     private IHaDocumentWrappper _lib;
 | |
| 
 | |
|     public CMIFController(IHaDocumentWrappper lib) {
 | |
|         _lib = lib;
 | |
|     }
 | |
| 
 | |
|     [Route("HKB/CMIF")]
 | |
|     [HttpGet]
 | |
|     [Produces("application/xml")]
 | |
|     public IActionResult CMIF() {
 | |
|         var lib = _lib.GetLibrary();
 | |
|         if (lib != null) {
 | |
|             var document = new TeiDocument(lib);
 | |
|             return Ok(document);
 | |
|         }
 | |
|         return NotFound();
 | |
|     }
 | |
| }
 | 
