ArangoDB2

 view release on metacpan or  search on metacpan

lib/ArangoDB2/Document.pm  view on Meta::CPAN

167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
    # make request
    return $self->arango->http->get(
        $self->api_path($self->_class),
        $args
    );
}
 
# update
#
# PATCH /_api/document/{document-handle}
sub update
{
    my($self, $data, $args) = @_;
    # process args
    $args = $self->_build_args($args, ['keepNull', 'policy', 'waitForSync']);
    # make request
    my $res = $self->arango->http->patch(
        $self->api_path($self->_class, $self->collection->name, $self->name),
        $args,
        $JSON->encode($data),
    ) or return;

lib/ArangoDB2/Graph/Vertex.pm  view on Meta::CPAN

103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
}
 
# keepNull
#
# get/set keepNull
sub keepNull { shift->_get_set_bool('keepNull', @_) }
 
# update
#
# PATCH /system/gharial/graph-name/vertex/collection-name/vertex-key
sub update
{
    my($self, $data, $args) = @_;
    # require data
    die "Invalid args"
        unless ref $data eq 'HASH';
    # process args
    $args = $self->_build_args($args, ['name', 'keepNull', 'waitForSync']);
    # make request
    my $res = $self->arango->http->patch(
        $self->api_path('gharial', $self->graph->name, $self->_class, $self->collection->name, delete $args->{name}),

lib/ArangoDB2/User.pm  view on Meta::CPAN

72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
    ) or return;
    # copy param data from res to self
    $self->_build_self($res, \@PARAMS);
 
    return $self;
}
 
# update
#
# PATCH /_api/user/{user}
sub update
{
    my($self, $args) = @_;
    # process request args
    $args = $self->_build_args($args, \@PARAMS);
    # make request
    my $res = $self->arango->http->patch(
        $self->api_path('user', delete $args->{name}),
        undef,
        $JSON->encode($args),
    ) or return;



( run in 0.488 second using v1.01-cache-2.11-cpan-49f99fa48dc )