Class Bibtex3Resource
java.lang.Object
org.ctan.site.resources.catalogue.Bibtex3Resource
The class
Bibtex3Resource contains the controller for the bibtex
resource.-
Constructor Summary
ConstructorsConstructorDescriptionBibtex3Resource(@NonNull BibtexService service) This is the constructor for the classBibtex3Resource. -
Method Summary
Modifier and TypeMethodDescriptiongetBibtex(@NonNull String key, String keyPrefix, boolean omitAbstract, boolean useString, String type) The methodgetBibtexcontains the end-point for /bibtex/key.getBibtexAll(String keyPrefix, boolean omitAbstract, boolean useString, String type) The methodgetBibtexAllcontains the end-point for /bibtex.
-
Constructor Details
-
Bibtex3Resource
This is the constructor for the classBibtex3Resource.- Parameters:
service- the underlying service
-
-
Method Details
-
getBibtex
@GET @Path("/bibtex/{key}") @PermitAll @UnitOfWork("siteDb") @Produces("text/plain") public String getBibtex(@NonNull @PathParam("key") @NonNull String key, @QueryParam("key-prefix") String keyPrefix, @QueryParam("omit-abstract") boolean omitAbstract, @QueryParam("use-string") boolean useString, @QueryParam("type") String type) The methodgetBibtexcontains the end-point for /bibtex/key. It returns the BibTeX file.- Parameters:
key- the keykeyPrefix- the key prefixomitAbstract- indicator to omit the abstractuseString- indicator to use the @String definitiontype- the type of the entry- Returns:
- the BibTeX file
-
getBibtexAll
@GET @Path("/bibtex") @PermitAll @UnitOfWork("siteDb") @Produces("text/plain;charset=UTF-8") public String getBibtexAll(@QueryParam("key-prefix") String keyPrefix, @QueryParam("omit-abstract") boolean omitAbstract, @QueryParam("use-string") boolean useString, @QueryParam("type") String type) The methodgetBibtexAllcontains the end-point for /bibtex. It returns the BibTeX file.Attention: This service is too slow to be exposable!
- Parameters:
keyPrefix- the key prefixomitAbstract- indicator to omit the abstractuseString- indicator to use the @String definitiontype- the type of the entry- Returns:
- the BibTeX file
-