@@ -799,6 +799,26 @@ public Cosh cosh() {
799
799
public Cosh cosh (AngularUnit unit ) {
800
800
return usesFieldRef () ? Cosh .coshOf (fieldReference , unit ) : Cosh .coshOf (expression , unit );
801
801
}
802
+
803
+ /**
804
+ * Creates new {@link AggregationExpression} that calculates the inverse cosine of a numeric value.
805
+ *
806
+ * @return new instance of {@link ACos}.
807
+ * @since 3.3
808
+ */
809
+ public ACos acos () {
810
+ return usesFieldRef () ? ACos .acosOf (fieldReference ) : ACos .acosOf (expression );
811
+ }
812
+
813
+ /**
814
+ * Creates new {@link AggregationExpression} that calculates the inverse hyperbolic cosine of a numeric value.
815
+ *
816
+ * @return new instance of {@link ACosh}.
817
+ * @since 3.3
818
+ */
819
+ public ACosh acosh () {
820
+ return usesFieldRef () ? ACosh .acoshOf (fieldReference ) : ACosh .acoshOf (expression );
821
+ }
802
822
803
823
/**
804
824
* Creates new {@link AggregationExpression} that calculates the tangent of a numeric value given in
@@ -2664,6 +2684,104 @@ protected String getMongoMethod() {
2664
2684
return "$cosh" ;
2665
2685
}
2666
2686
}
2687
+
2688
+ /**
2689
+ * An {@link AggregationExpression expression} that calculates the inverse cosine of a value.
2690
+ *
2691
+ */
2692
+ public static class ACos extends AbstractAggregationExpression {
2693
+
2694
+ private ACos (Object value ) {
2695
+ super (value );
2696
+ }
2697
+
2698
+ /**
2699
+ * Creates a new {@link AggregationExpression} that calculates the inverse cosine of a value.
2700
+ *
2701
+ * @param fieldReference the name of the {@link Field field} that resolves to a numeric value.
2702
+ * @return new instance of {@link ACos}.
2703
+ */
2704
+ public static ACos acosOf (String fieldReference ) {
2705
+
2706
+ Assert .notNull (fieldReference , "FieldReference must not be null!" );
2707
+ return new ACos (Fields .field (fieldReference ));
2708
+ }
2709
+
2710
+ /**
2711
+ * Creates a new {@link AggregationExpression} that calculates the inverse cosine of a value.
2712
+ * <br />
2713
+ *
2714
+ * @param expression the {@link AggregationExpression expression} that resolves to a numeric value.
2715
+ * @return new instance of {@link ACos}.
2716
+ */
2717
+ public static ACos acosOf (AggregationExpression expression ) {
2718
+ return new ACos (expression );
2719
+ }
2720
+
2721
+ /**
2722
+ * Creates a new {@link AggregationExpression} that calculates the inverse cosine of a value.
2723
+ *
2724
+ * @param value anything ({@link Field field}, {@link AggregationExpression expression}, ...) that resolves to a
2725
+ * numeric value.
2726
+ * @return new instance of {@link ACos}.
2727
+ */
2728
+ public static ACos acosOf (Number value ) {
2729
+ return new ACos (value );
2730
+ }
2731
+
2732
+ @ Override
2733
+ protected String getMongoMethod () {
2734
+ return "$acos" ;
2735
+ }
2736
+ }
2737
+
2738
+ /**
2739
+ * An {@link AggregationExpression expression} that calculates the inverse hyperbolic cosine of a value
2740
+ *
2741
+ */
2742
+ public static class ACosh extends AbstractAggregationExpression {
2743
+
2744
+ private ACosh (Object value ) {
2745
+ super (value );
2746
+ }
2747
+
2748
+ /**
2749
+ * Creates a new {@link AggregationExpression} that calculates the inverse hyperbolic cosine of a value.
2750
+ *
2751
+ * @param fieldReference the name of the {@link Field field} that resolves to a numeric value.
2752
+ * @return new instance of {@link ACosh}.
2753
+ */
2754
+ public static ACosh acoshOf (String fieldReference ) {
2755
+ return new ACosh (Fields .field (fieldReference ));
2756
+ }
2757
+
2758
+ /**
2759
+ * Creates a new {@link AggregationExpression} that calculates the inverse hyperbolic cosine of a value.
2760
+ * <br />
2761
+ *
2762
+ * @param expression the {@link AggregationExpression expression} that resolves to a numeric value.
2763
+ * @return new instance of {@link ACosh}.
2764
+ */
2765
+ public static ACosh acoshOf (AggregationExpression expression ) {
2766
+ return new ACosh (expression );
2767
+ }
2768
+
2769
+ /**
2770
+ * Creates a new {@link AggregationExpression} that calculates the inverse hyperbolic cosine of a value.
2771
+ *
2772
+ * @param value anything ({@link Field field}, {@link AggregationExpression expression}, ...) that resolves to a
2773
+ * numeric value.
2774
+ * @return new instance of {@link ACosh}.
2775
+ */
2776
+ public static ACosh acoshOf (Object value ) {
2777
+ return new ACosh (value );
2778
+ }
2779
+
2780
+ @ Override
2781
+ protected String getMongoMethod () {
2782
+ return "$acosh" ;
2783
+ }
2784
+ }
2667
2785
2668
2786
/**
2669
2787
* An {@link AggregationExpression expression} that calculates the tangent of a value that is measured in radians.
0 commit comments