001/*-
002 * #%L
003 * HAPI FHIR - Master Data Management
004 * %%
005 * Copyright (C) 2014 - 2024 Smile CDR, Inc.
006 * %%
007 * Licensed under the Apache License, Version 2.0 (the "License");
008 * you may not use this file except in compliance with the License.
009 * You may obtain a copy of the License at
010 *
011 *      http://www.apache.org/licenses/LICENSE-2.0
012 *
013 * Unless required by applicable law or agreed to in writing, software
014 * distributed under the License is distributed on an "AS IS" BASIS,
015 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
016 * See the License for the specific language governing permissions and
017 * limitations under the License.
018 * #L%
019 */
020package ca.uhn.fhir.mdm.api.paging;
021
022import java.util.Optional;
023
024/**
025 * Data clump class to keep the relevant paging URLs together for MDM.
026 */
027public class MdmPageLinkTuple {
028        private String myPreviousLink = null;
029        private String mySelfLink = null;
030        private String myNextLink = null;
031
032        MdmPageLinkTuple() {}
033
034        public Optional<String> getPreviousLink() {
035                return Optional.ofNullable(myPreviousLink);
036        }
037
038        public void setPreviousLink(String thePreviousLink) {
039                this.myPreviousLink = thePreviousLink;
040        }
041
042        public String getSelfLink() {
043                return mySelfLink;
044        }
045
046        public void setSelfLink(String theSelfLink) {
047                this.mySelfLink = theSelfLink;
048        }
049
050        public Optional<String> getNextLink() {
051                return Optional.ofNullable(myNextLink);
052        }
053
054        public void setNextLink(String theNextLink) {
055                this.myNextLink = theNextLink;
056        }
057}