001/* 002 * Copyright (c) 2007-2015 Concurrent, Inc. All Rights Reserved. 003 * 004 * Project and contact information: http://www.cascading.org/ 005 * 006 * This file is part of the Cascading project. 007 * 008 * Licensed under the Apache License, Version 2.0 (the "License"); 009 * you may not use this file except in compliance with the License. 010 * You may obtain a copy of the License at 011 * 012 * http://www.apache.org/licenses/LICENSE-2.0 013 * 014 * Unless required by applicable law or agreed to in writing, software 015 * distributed under the License is distributed on an "AS IS" BASIS, 016 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 017 * See the License for the specific language governing permissions and 018 * limitations under the License. 019 */ 020 021package cascading.flow.planner.graph; 022 023import java.util.Set; 024 025import cascading.flow.FlowElement; 026import cascading.flow.planner.Scope; 027import cascading.property.ConfigDef; 028import cascading.tuple.Fields; 029 030/** 031 * Enum Extent provides simple markers for the head and tail of an {@link ElementGraph} {@link FlowElement} graph. 032 */ 033public enum Extent implements FlowElement 034 { 035 head, 036 tail; 037 038 @Override 039 public Scope outgoingScopeFor( Set<Scope> scopes ) 040 { 041 return new Scope(); 042 } 043 044 @Override 045 public Fields resolveIncomingOperationArgumentFields( Scope incomingScope ) 046 { 047 return null; 048 } 049 050 @Override 051 public Fields resolveIncomingOperationPassThroughFields( Scope incomingScope ) 052 { 053 return null; 054 } 055 056 @Override 057 public boolean isEquivalentTo( FlowElement element ) 058 { 059 return false; 060 } 061 062 @Override 063 public ConfigDef getStepConfigDef() 064 { 065 return null; 066 } 067 068 @Override 069 public boolean hasStepConfigDef() 070 { 071 return false; 072 } 073 074 @Override 075 public ConfigDef getNodeConfigDef() 076 { 077 return null; 078 } 079 080 @Override 081 public boolean hasNodeConfigDef() 082 { 083 return false; 084 } 085 086 @Override 087 public ConfigDef getConfigDef() 088 { 089 return null; 090 } 091 092 @Override 093 public boolean hasConfigDef() 094 { 095 return false; 096 } 097 098 @Override 099 public String toString() 100 { 101 return "[" + name() + "]"; 102 } 103 }