.\" Copyright (C) 1994-2018 Altair Engineering, Inc.
.\" For more information, contact Altair at www.altair.com.
.\"
.\" This file is part of the PBS Professional ("PBS Pro") software.
.\"
.\" Open Source License Information:
.\"
.\" PBS Pro is free software. You can redistribute it and/or modify it under the
.\" terms of the GNU Affero General Public License as published by the Free
.\" Software Foundation, either version 3 of the License, or (at your option) any
.\" later version.
.\"
.\" PBS Pro is distributed in the hope that it will be useful, but WITHOUT ANY
.\" WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
.\" FOR A PARTICULAR PURPOSE.
.\" See the GNU Affero General Public License for more details.
.\"
.\" You should have received a copy of the GNU Affero General Public License
.\" along with this program. If not, see .
.\"
.\" Commercial License Information:
.\"
.\" For a copy of the commercial license terms and conditions,
.\" go to: (http://www.pbspro.com/UserArea/agreement.html)
.\" or contact the Altair Legal Department.
.\"
.\" Altair’s dual-license business model allows companies, individuals, and
.\" organizations to create proprietary derivative works of PBS Pro and
.\" distribute them - whether embedded or bundled with other software -
.\" under a commercial license agreement.
.\"
.\" Use of Altair’s trademarks, including but not limited to "PBS™",
.\" "PBS Professional®", and "PBS Pro™" and Altair’s logos is subject to Altair's
.\" trademark licensing policies.
.\"
.TH pbs_modify_resv 3B "20 February 2018" Local "PBS Professional"
.SH NAME
pbs_modify_resv - modify a PBS reservation
.SH SYNOPSIS
#include
.br
#include
.sp
.B char *pbs_modify_resv(int server_connect, char *resv_id, struct attropl *attrib, char *extend)
.SH DESCRIPTION
Issue a batch request to modify a reservation.
.LP
A
.I "Modify Reservation"
batch request is generated and sent to the server.
The parameter
.I server_connect
is the socket on which we connect to the server.
The parameter
.I resv_id
is the reservation ID.
.LP
The parameter
.I attrib
is a list of attributes to be changed.
Each attribute is an
.I attropl
structure which is defined in pbs_ifl.h as:
.sp
.Ty
.nf
struct attrl {
char *name;
char *resource;
char *value;
struct attrl *next;
enum batch_op op;
};
.fi
.sp
The
.I attrib
list is terminated by the first entry where
.I next
is a null pointer.
.LP
The
.I name
member points to a string which is the name of the attribute. The
.I value
member points to a string which is the value of the attribute.
The attribute names are defined in pbs_ifl.h.
.LP
If an attribute is not named in the
.I attrib
array, the default action is taken. It is either assigned
the default value or is not passed with the reservation. The action
depends on the attribute.
If
.I attrib
itself is a null pointer, then the default action is taken for
each attribute.
.LP
An attribute of type ATTR_l (the letter ell) has
a resource name indicated by
.I resource
in the
.I attrl
structure.
All other attribute types should have a pointer to a null string for
.I resource.
.LP
The
.I op
member is forced to a value of
.I SET
by pbs_modify_resv().
.LP
The parameter,
.I extend,
is reserved for implementation-defined extensions.
.LP
The return value is a character string which is the
.I reservation identifier
assigned to the job by the server.
The space for the
.I reservation identifier
string is allocated by \f3pbs_modify_resv\f1()
and should be released via a call to \f3free\f1()
by the user when no longer needed.
.SH "SEE ALSO"
pbs_rsub(1B) and pbs_connect(3B)
.SH DIAGNOSTICS
When the batch request generated by pbs_modify_resv()
function has been completed successfully by a batch server, the routine will
return a pointer to a character string which is the reservation identifier of the
modified reservation.
Otherwise, a null pointer is returned and the error code is set in pbs_error.