Skip to content

Commit

Permalink
updated javadocs
Browse files Browse the repository at this point in the history
  • Loading branch information
albogdano committed Apr 27, 2024
1 parent d758faa commit 37fbaa6
Show file tree
Hide file tree
Showing 20 changed files with 192 additions and 29 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ public final class Version {
private static final String GIT_BRANCH = "${scmBranch}";
private static final String REVISION = "${buildNumber}";

private Version() { }

public static String getVersion() {
return VERSION;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,7 @@ public int getOrder() {
}

/**
* Filter.
* @return API servlet bean
*/
@Bean
Expand All @@ -249,6 +250,7 @@ public ServletRegistrationBean<?> apiV1RegistrationBean() {
}

/**
* Filter.
* @return GZIP filter bean
*/
@Bean
Expand All @@ -265,6 +267,7 @@ public FilterRegistrationBean<?> gzipFilterRegistrationBean() {
}

/**
* Filter.
* @return CORS filter bean
*/
@Bean
Expand All @@ -287,6 +290,7 @@ public FilterRegistrationBean<?> corsFilterRegistrationBean() {
}

/**
* Jetty config.
* @return Jetty config bean
*/
@Bean
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,12 @@
*/
public class AOPModule extends AbstractModule {

/**
* Default constructor.
*/
public AOPModule() {
}

protected void configure() {
// enable automatic indexing and caching each time an object is created/updated
IndexAndCacheAspect coreAspect = new IndexAndCacheAspect();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,18 @@
*/
package com.erudika.para.server.aop;

import com.erudika.para.core.listeners.IOListener;
import com.erudika.para.core.utils.Para;
import com.erudika.para.core.ParaObject;
import com.erudika.para.core.annotations.Cached;
import com.erudika.para.core.annotations.Indexed;
import com.erudika.para.core.cache.Cache;
import com.erudika.para.core.ParaObject;
import com.erudika.para.core.listeners.IOListener;
import com.erudika.para.core.metrics.Metrics;
import com.erudika.para.core.persistence.DAO;
import com.erudika.para.core.search.Search;
import com.erudika.para.core.utils.Para;
import com.erudika.para.core.utils.Utils;
import com.erudika.para.core.validation.ValidationUtils;
import jakarta.inject.Inject;
import java.lang.reflect.Method;
import java.lang.reflect.Modifier;
import java.util.ArrayList;
Expand All @@ -38,7 +39,6 @@
import java.util.Map;
import java.util.Set;
import java.util.stream.Collectors;
import jakarta.inject.Inject;
import org.aopalliance.intercept.MethodInterceptor;
import org.aopalliance.intercept.MethodInvocation;
import org.slf4j.Logger;
Expand All @@ -62,13 +62,21 @@ public class IndexAndCacheAspect implements MethodInterceptor {
private Cache cache;

/**
* Constructor.
*/
public IndexAndCacheAspect() {
}

/**
* getter/setter.
* @return {@link Search}
*/
public Search getSearch() {
return search;
}

/**
* getter/setter.
* @param search {@link Search}
*/
@Inject
Expand All @@ -77,13 +85,15 @@ public void setSearch(Search search) {
}

/**
* getter/setter.
* @return {@link Cache}
*/
public Cache getCache() {
return cache;
}

/**
* getter/setter.
* @param cache {@link Cache}
*/
@Inject
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@
*/
public class CacheModule extends AbstractModule {

/**
* Constructor.
*/
public CacheModule() {
}

protected void configure() {
String selectedCache = Para.getConfig().cachePlugin();
if (StringUtils.isBlank(selectedCache) || "inmemory".equalsIgnoreCase(selectedCache)) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@
*/
public class EmailModule extends AbstractModule {

/**
* Constructor.
*/
public EmailModule() {
}

protected void configure() {
String selectedEmailer = Para.getConfig().emailerPlugin();
if (StringUtils.isBlank(selectedEmailer)) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@ public class NoopEmailer implements Emailer {

private static final Logger logger = LoggerFactory.getLogger(NoopEmailer.class);

/**
* Constructor.
*/
public NoopEmailer() {
}

@Override
public boolean sendEmail(List<String> emails, String subject, String body) {
logger.info("EMAIL SENT: {}, {}, {}", emails, subject, body);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,17 @@
import com.erudika.para.core.queue.MockQueue;
import com.erudika.para.core.queue.Queue;
import com.erudika.para.core.utils.Para;
import jakarta.inject.Singleton;
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.ConcurrentLinkedQueue;
import java.util.concurrent.Future;
import jakarta.inject.Singleton;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
*
* Local queue impl.
* @author Alex Bogdanovski [alex@erudika.com]
*/
@Singleton
Expand All @@ -54,6 +54,7 @@ public LocalQueue() {
}

/**
* getter/setter.
* @param name name
*/
public LocalQueue(String name) {
Expand Down
26 changes: 26 additions & 0 deletions para-server/src/main/java/com/erudika/para/server/rest/Api1.java
Original file line number Diff line number Diff line change
Expand Up @@ -381,6 +381,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param app {@link App}
* @param type a type
* @return response
Expand Down Expand Up @@ -414,6 +415,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @return response
*/
public static Inflector<ContainerRequestContext, Response> linksHandler() {
Expand Down Expand Up @@ -459,6 +461,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @return response
*/
public static Inflector<ContainerRequestContext, Response> meHandler() {
Expand Down Expand Up @@ -497,6 +500,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @return response
*/
public static Inflector<ContainerRequestContext, Response> readIdHandler() {
Expand All @@ -513,6 +517,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @return response
*/
public static Inflector<ContainerRequestContext, Response> configOptionsHandler() {
Expand All @@ -535,6 +540,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand All @@ -556,6 +562,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand Down Expand Up @@ -583,6 +590,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand All @@ -605,6 +613,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand All @@ -626,6 +635,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand All @@ -646,6 +656,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand Down Expand Up @@ -687,6 +698,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand Down Expand Up @@ -714,6 +726,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand Down Expand Up @@ -824,6 +837,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @param type a type
* @return response
Expand All @@ -838,6 +852,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @param type a type
* @return response
Expand All @@ -857,6 +872,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @param type a type
* @return response
Expand All @@ -876,6 +892,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @param type a type
* @return response
Expand All @@ -891,6 +908,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @param type a type
* @return response
Expand All @@ -907,6 +925,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand All @@ -920,6 +939,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand All @@ -933,6 +953,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand All @@ -959,6 +980,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand All @@ -972,6 +994,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param app {@link App}
* @param type a type
* @return response
Expand All @@ -996,6 +1019,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @return response
*/
public static Inflector<ContainerRequestContext, Response> reindexHandler() {
Expand All @@ -1022,6 +1046,7 @@ public Response apply(ContainerRequestContext ctx) {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand Down Expand Up @@ -1067,6 +1092,7 @@ public void write(OutputStream os) throws IOException, WebApplicationException {
}

/**
* Api method.
* @param a {@link App}
* @return response
*/
Expand Down
Loading

0 comments on commit 37fbaa6

Please sign in to comment.