001package ca.uhn.fhir.model.base.composite; 002 003import ca.uhn.fhir.i18n.Msg; 004import ca.uhn.fhir.model.api.IDatatype; 005import ca.uhn.fhir.model.api.IResource; 006import ca.uhn.fhir.util.CoverageIgnore; 007 008import java.util.List; 009 010/* 011 * #%L 012 * HAPI FHIR - Core Library 013 * %% 014 * Copyright (C) 2014 - 2022 Smile CDR, Inc. 015 * %% 016 * Licensed under the Apache License, Version 2.0 (the "License"); 017 * you may not use this file except in compliance with the License. 018 * You may obtain a copy of the License at 019 * 020 * http://www.apache.org/licenses/LICENSE-2.0 021 * 022 * Unless required by applicable law or agreed to in writing, software 023 * distributed under the License is distributed on an "AS IS" BASIS, 024 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 025 * See the License for the specific language governing permissions and 026 * limitations under the License. 027 * #L% 028 */ 029 030public abstract class BaseContainedDt implements IDatatype { 031 032 private static final long serialVersionUID = 1L; 033 034 public abstract List<? extends IResource> getContainedResources(); 035 036 /** 037 * NOT SUPPORTED - Throws {@link UnsupportedOperationException} 038 */ 039 @Override 040 @CoverageIgnore 041 public List<String> getFormatCommentsPost() { 042 throw new UnsupportedOperationException(Msg.code(1901)); 043 } 044 045 /** 046 * NOT SUPPORTED - Throws {@link UnsupportedOperationException} 047 */ 048 @Override 049 @CoverageIgnore 050 public List<String> getFormatCommentsPre() { 051 throw new UnsupportedOperationException(Msg.code(1902)); 052 } 053 054 /** 055 * Returns false 056 */ 057 @Override 058 @CoverageIgnore 059 public boolean hasFormatComment() { 060 return false; 061 } 062 063}