Package com.couchbase.client.java.view
Class DefaultView
- java.lang.Object
-
- com.couchbase.client.java.view.DefaultView
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
DefaultView(String name, String map, String reduce)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static View
create(String name, String map)
Create a new representation of a regular, non-spatial view without reduce function.static View
create(String name, String map, String reduce)
Create a new representation of a regular, non-spatial view.boolean
equals(Object o)
int
hashCode()
boolean
hasReduce()
If a reduce function is set or not.String
map()
The map functionString
name()
The name of the view.String
reduce()
The reduce function.String
toString()
-
-
-
Method Detail
-
create
public static View create(String name, String map, String reduce)
Create a new representation of a regular, non-spatial view.- Parameters:
name
- the name of the view.map
- the map function (javascript) for the view.reduce
- the reduce function (prebuilt name or custom javascript) for the view. Usecreate(String, String)
or null if you don't need one.- Returns:
- the view object.
-
create
public static View create(String name, String map)
Create a new representation of a regular, non-spatial view without reduce function.- Parameters:
name
- the name of the view.map
- the map function (javascript) for the view.- Returns:
- the view object.
-
hasReduce
public boolean hasReduce()
Description copied from interface:View
If a reduce function is set or not.
-
-