--- /dev/null
+/*\r
+\r
+ Derby - Class org.apache.derby.iapi.sql.depend.Dependent\r
+\r
+ Licensed to the Apache Software Foundation (ASF) under one or more\r
+ contributor license agreements. See the NOTICE file distributed with\r
+ this work for additional information regarding copyright ownership.\r
+ The ASF licenses this file to you under the Apache License, Version 2.0\r
+ (the "License"); you may not use this file except in compliance with\r
+ the License. You may obtain a copy of the License at\r
+\r
+ http://www.apache.org/licenses/LICENSE-2.0\r
+\r
+ Unless required by applicable law or agreed to in writing, software\r
+ distributed under the License is distributed on an "AS IS" BASIS,\r
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+ See the License for the specific language governing permissions and\r
+ limitations under the License.\r
+\r
+ */\r
+\r
+package org.apache.derby.iapi.sql.depend;\r
+\r
+import org.apache.derby.catalog.Dependable;\r
+\r
+import org.apache.derby.iapi.error.StandardException;\r
+\r
+import org.apache.derby.iapi.sql.conn.LanguageConnectionContext;\r
+\r
+/**\r
+ A dependent has the ability to know whether or not it\r
+ is valid and to mark itself as valid or invalid.\r
+ Marking itself as invalid usually means it cannot be used\r
+ in the system until it is revalidated, but this is in no\r
+ way enforced by this interface.\r
+ */\r
+public interface Dependent extends Dependable\r
+{\r
+\r
+ /**\r
+ Check that all of the dependent's dependencies are valid.\r
+\r
+ @return true if the dependent is currently valid\r
+ */\r
+ boolean isValid();\r
+\r
+ /**\r
+ Prepare to mark the dependent as invalid (due to at least one of\r
+ its dependencies being invalid).\r
+\r
+ @param action The action causing the invalidation\r
+ @param p the provider\r
+ @param lcc The LanguageConnectionContext\r
+\r
+ @exception StandardException thrown if unable to make it invalid\r
+ */\r
+ void prepareToInvalidate(Provider p, int action, \r
+ LanguageConnectionContext lcc) \r
+ throws StandardException;\r
+\r
+ /**\r
+ Mark the dependent as invalid (due to at least one of\r
+ its dependencies being invalid).\r
+\r
+ @param action The action causing the invalidation\r
+ @param lcc The LanguageConnectionContext\r
+\r
+ @exception StandardException thrown if unable to make it invalid\r
+ */\r
+ void makeInvalid(int action,\r
+ LanguageConnectionContext lcc) \r
+ throws StandardException;\r
+}\r