Skip to content

Commit

Permalink
Update javadoc
Browse files Browse the repository at this point in the history
  • Loading branch information
pranavpandey committed Jul 9, 2023
1 parent 89557a4 commit f4480b3
Show file tree
Hide file tree
Showing 34 changed files with 100 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@
* the bottom sheet according to the scroll direction.
*
* <p>Scrolling in downwards direction will hide the bottom sheet.
*
* @param <V> The type of the view attached to this behavior.
*/
public class DynamicBottomSheetBehavior<V extends View> extends BottomSheetBehavior<V> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
* A callback that notifies clients when the progress level has been changed.
* <p>This includes changes that were initiated by the user through a touch gesture
* or arrow key/trackball as well as changes that were initiated programmatically.
*
* @param <S> The type of the slider attached to this listener.
*/
public interface DynamicSliderChangeListener<S> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
* A callback that notifies clients when the progress level has been changed.
* <p>This includes changes that were initiated by the user through a touch gesture
* or arrow key/trackball as well as changes that were initiated programmatically.
*
* @param <S> The type of the slider attached to this resolver.
*/
public interface DynamicSliderResolver<S> extends DynamicSliderChangeListener<S> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@

/**
* An interface to get the various callbacks related to the dynamic theme.
*
* @param <T> The type of the dynamic app theme this resolver will resolve.
*/
public interface DynamicThemeResolver<T extends DynamicAppTheme> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@

/**
* An interface to get the value callbacks.
*
* @param <T> The type of the value.
*/
public interface DynamicValueListener<T> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@
/**
* A customisable {@link AppWidgetProvider} to provide basic configuration functionality.
* <p>Extend it and modify according to the requirements.
*
* @param <T> The type of the app theme attached to this provider.
*/
@TargetApi(Build.VERSION_CODES.JELLY_BEAN)
public abstract class DynamicAppWidgetProvider<T extends AppTheme<?>>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@
*
* <p>Extend this adapter and use {@link DynamicRecyclerViewBinder} to create binding logic
* for the each type of views.
*
* @param <VB> The type of the dynamic recycler view binder.
*/
@SuppressWarnings({"rawtypes", "unchecked"})
public abstract class DynamicBinderAdapter<VB extends DynamicRecyclerViewBinder>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@

/**
* A {@link ListAdapter} to handle the generic data.
*
* @param <T> The type of the lists this adapter will receive.
* @param <VH> The type of the recycler view holder.
*/
public abstract class DynamicListAdapter<T, VH extends RecyclerView.ViewHolder>
extends ListAdapter<T, VH> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@
*
* <p>Extend this adapter and implement {@link DynamicRecyclerViewItem} interface
* in the object class.
*
* @param <VH> The type of the recycler view holder.
*/
public abstract class DynamicRecyclerViewAdapter<VH extends RecyclerView.ViewHolder>
extends RecyclerView.Adapter<VH> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
/**
* A simple recycler view adapter to implement the {@link DynamicBinderAdapter}
* and {@link DynamicRecyclerViewBinder}.
*
* @param <VB> The type of the dynamic recycler view binder.
*/
public abstract class DynamicSimpleBinderAdapter<VB extends DynamicRecyclerViewBinder<?>>
extends DynamicBinderAdapter<VB> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@

/**
* A {@link DynamicBinderAdapter} to display different type of {@link VB} inside a recycler view.
*
* @param <E> The type of the enum this adapter will receive.
* @param <VB> The type of the dynamic recycler view binder.
*/
public abstract class DynamicTypeBinderAdapter<E extends Enum<E>,
VB extends DynamicRecyclerViewBinder<?>> extends DynamicBinderAdapter<VB> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@

/**
* A {@link DynamicListAdapter} to handle the generic data with query.
*
* @param <T> The type of the lists this adapter will receive.
* @param <Q> The type of the query this adapter will receive.
* @param <VH> The type of the recycler view holder.
*/
public abstract class DynamicListQueryAdapter<T, Q, VH extends RecyclerView.ViewHolder>
extends DynamicListAdapter<T, VH> implements Filterable {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@
/**
* A {@link DynamicSimpleBinderAdapter} to handle the generic data that can be used
* with the {@link com.pranavpandey.android.dynamic.support.recyclerview.binder.DynamicDataBinder}.
*
* @param <T> The type of the data this adapter will receive.
* @param <VB> The type of the dynamic recycler view binder.
*/
public abstract class SimpleDataBinderAdapter<T, VB extends DynamicRecyclerViewBinder<?>>
extends DynamicSimpleBinderAdapter<VB> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
/**
* A {@link SimpleDataBinderAdapter} to handle the generic data with query that can be used
* with the {@link com.pranavpandey.android.dynamic.support.recyclerview.binder.DynamicQueryBinder}.
*
* @param <T> The type of the data this adapter will receive.
* @param <Q> The type of the query this adapter will receive.
* @param <VB> The type of the dynamic recycler view binder.
*/
public abstract class SimpleQueryBinderAdapter<T, Q, VB extends DynamicRecyclerViewBinder<?>>
extends SimpleDataBinderAdapter<T, VB> implements Filterable {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@
/**
* A {@link DynamicTypeBinderAdapter} to handle the generic data that can be used
* with the {@link com.pranavpandey.android.dynamic.support.recyclerview.binder.DynamicDataBinder}.
*
* @param <T> The type of the data this adapter will receive.
* @param <E> The type of the enum this adapter will receive.
* @param <VB> The type of the dynamic recycler view binder.
*/
public abstract class TypeDataBinderAdapter<T, E extends Enum<E>,
VB extends DynamicRecyclerViewBinder<?>> extends DynamicTypeBinderAdapter<E, VB> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,11 @@
/**
* A {@link TypeDataBinderAdapter} to handle the generic data with query that can be used
* with the {@link com.pranavpandey.android.dynamic.support.recyclerview.binder.DynamicQueryBinder}.
*
* @param <T> The type of the data this adapter will receive.
* @param <Q> The type of the query this adapter will receive.
* @param <E> The type of the enum this adapter will receive.
* @param <VB> The type of the dynamic recycler view binder.
*/
public abstract class TypeQueryBinderAdapter<T, Q, E extends Enum<E>,
VB extends DynamicRecyclerViewBinder<?>> extends TypeDataBinderAdapter<T, E, VB>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@
/**
* A {@link DynamicRecyclerViewBinder} to bind the generic data that can be used
* with the {@link DynamicBinderAdapter}.
*
* @param <T> The type of the data this binder will receive.
* @param <VH> The type of the dynamic recycler view binder.
*/
public abstract class DynamicDataBinder<T, VH extends RecyclerView.ViewHolder>
extends DynamicRecyclerViewBinder<VH> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
/**
* A {@link DynamicDataBinder} to bind the generic data with query that can be used
* with the {@link DynamicBinderAdapter}.
*
* @param <T> The type of the data this binder will receive.
* @param <Q> The type of the query this binder will receive.
* @param <VH> The type of the dynamic recycler view binder.
*/
public abstract class DynamicQueryBinder<T, Q, VH extends RecyclerView.ViewHolder>
extends DynamicDataBinder<T, VH> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
/**
* A data binder class to bind data with the view inside the {@link DynamicBinderAdapter}.
* <p>Extend this class to implement your own data binding logic.
*
* @param <VH> The type of the dynamic recycler view binder.
*/
@SuppressWarnings({"rawtypes", "unchecked"})
public abstract class DynamicRecyclerViewBinder<VH extends RecyclerView.ViewHolder> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@
/**
* A {@link DynamicQueryBinder} to bind the {@link DynamicInfo} that can be used
* with the {@link DynamicBinderAdapter}.
*
* @param <Query> The type of the query this binder will receive.
*/
public class InfoBinder<Query> extends DynamicQueryBinder<
DynamicInfo, Query, InfoBinder.ViewHolder> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
/**
* An {@link InfoBinder} to bind the {@link DynamicInfo} inside a
* {@link androidx.cardview.widget.CardView} that can be used with the {@link DynamicBinderAdapter}.
*
* @param <Query> The type of the query this binder will receive.
*/
public class InfoCardBinder<Query> extends InfoBinder<Query> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@

/**
* A {@link DynamicSpinnerPreference} to display and edit the {@link DynamicAppTheme}.
*
* @param <T> The type of the dynamic app theme this preference will handle.
*/
public abstract class ThemePreference<T extends DynamicAppTheme>
extends DynamicSpinnerPreference implements DynamicThemeResolver<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@

/**
* A recycler view adapter to show the theme presets.
*
@param <T> The type of the dynamic app theme this adapter will receive.
*/
public class DynamicPresetsAdapter<T extends DynamicAppTheme>
extends DynamicRecyclerViewAdapter<DynamicPresetsAdapter.ViewHolder<T>> {
Expand Down Expand Up @@ -234,6 +236,8 @@ public void setDynamicPresetsListener(

/**
* View holder class to hold the preset view.
*
@param <T> The type of the dynamic app theme this view holder will handle.
*/
public static class ViewHolder<T extends DynamicAppTheme> extends RecyclerView.ViewHolder {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@

/**
* A dialog fragment to import a dynamic theme.
*
* @param <T> The type of the dynamic app theme this dialog will handle.
* @param <V> The type of the theme source.
*/
public class DynamicThemeDialog<T extends DynamicAppTheme, V> extends DynamicDialogFragment {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@
/**
* Base theme fragment to provide theme editing functionality.
* <p>Extend this fragment to implement theme attributes according to the requirements.
*
* @param <T> The type of the dynamic app theme this fragment will handle.
*/
public abstract class ThemeFragment<T extends DynamicAppTheme> extends DynamicFragment
implements ThemeListener.Value, ThemeListener.Import<T>, ThemeListener.Export<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@

/**
* Interface to listen various theme events.
*
* @param <T> The type of the dynamic app theme.
*/
public interface ThemeListener<T extends DynamicAppTheme> {

Expand Down Expand Up @@ -313,11 +315,15 @@ interface Value {

/**
* Interface to listen the theme import events.
*
* @param <T> The type of the dynamic app theme.
*/
interface Import<T extends DynamicAppTheme> {

/**
* Interface to listen the theme import (from file) events.
*
* @param <T> The type of the theme source.
*/
interface File<T> {

Expand Down Expand Up @@ -370,6 +376,8 @@ interface File<T> {

/**
* Interface to listen the theme export events.
*
* @param <T> The type of the dynamic app theme.
*/
interface Export<T extends DynamicAppTheme> extends ThemeListener<T> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@

/**
* A {@link DynamicTask} to perform the theme related operations.
*
* @param <V> The type of the dynamic app theme.
*/
public abstract class ThemeExportTask<V extends DynamicAppTheme>
extends DynamicTask<Void, Void, Uri> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@

/**
* A {@link DynamicTask} to perform the theme import operations.
*
* @param <T> The type of the dynamic app theme.
*/
public abstract class ThemeImportTask<T> extends ContextTask<Void, Void, String> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,16 @@

/**
* A recycler view frame layout to show the theme presets.
*
* @param <T> The type of the dynamic app theme this view will handle.
*/
public class DynamicPresetsView<T extends DynamicAppTheme>
extends DynamicRecyclerViewNested implements DefaultLifecycleObserver {

/**
* Listener to get the preset theme and click events.
*
* @param <T> The type of the dynamic app theme.
*/
public interface DynamicPresetsListener<T extends DynamicAppTheme> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@

/**
* A {@link DynamicView} to show the theme preview according to the {@link DynamicAppTheme}.
*
* @param <T> The type of the dynamic app theme this preview will handle.
*/
public abstract class ThemePreview<T extends DynamicAppTheme> extends DynamicView {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,17 @@
*
* <p>Any child view or fragment must implement this interface to support any color
* transitions.
*
* @param <T> The type of the tutorial.
* @param <V> The type of the view or fragment.
*/
public interface Tutorial<T, V> extends ViewPager.OnPageChangeListener {

/**
* A {@link Tutorial} to support animation(s) and shared element(s) transition.
*
* @param <T> The type of the tutorial.
* @param <V> The type of the view or fragment.
*/
interface Motion<T, V> extends Tutorial<T, V> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@
/**
* Base activity with a view pager to show the supplied tutorials.
* <p>Extend this activity and supply tutorials or dataSet by using the provided methods.
*
* @param <V> The type of the view or fragment this activity will handle.
* @param <T> The type of the tutorial this activity will handle.
*/
public abstract class DynamicTutorialActivity<V extends Fragment, T extends Tutorial<T, V>>
extends DynamicSystemActivity implements DynamicTransitionListener, DynamicSnackbar {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@

/**
* A {@link DynamicFragmentStateAdapter} to display the supplied {@link Tutorial}.
*
* @param <V> The type of the view or fragment this adapter will handle.
* @param <T> The type of the tutorial this adapter will handle.
*/
public class DynamicTutorialsAdapter<V extends Fragment, T extends Tutorial<T, V>>
extends DynamicFragmentStateAdapter {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
/**
* Interface to create dynamic widgets with corner radius support which can be used to modify
* it at runtime according to the {@link DynamicTheme}.
*
* @param <T> The type of the corner radius.
*/
public interface DynamicCornerWidget<T> {

Expand Down

0 comments on commit f4480b3

Please sign in to comment.