Fix #1693310 Missing function/method declaration in the completion list
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / internal / compiler / ast / Reference.java
1 /*******************************************************************************
2  * Copyright (c) 2000, 2003 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials 
4  * are made available under the terms of the Common Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/cpl-v10.html
7  * 
8  * Contributors:
9  *     IBM Corporation - initial API and implementation
10  *******************************************************************************/
11 package net.sourceforge.phpdt.internal.compiler.ast;
12
13 import net.sourceforge.phpdt.internal.compiler.flow.FlowContext;
14 import net.sourceforge.phpdt.internal.compiler.flow.FlowInfo;
15 import net.sourceforge.phpdt.internal.compiler.lookup.BlockScope;
16 import net.sourceforge.phpdt.internal.compiler.lookup.FieldBinding;
17
18 public abstract class Reference extends Expression {
19         /**
20          * BaseLevelReference constructor comment.
21          */
22         public Reference() {
23                 super();
24         }
25
26         public abstract FlowInfo analyseAssignment(BlockScope currentScope,
27                         FlowContext flowContext, FlowInfo flowInfo, Assignment assignment,
28                         boolean isCompound);
29
30         public FlowInfo analyseCode(BlockScope currentScope,
31                         FlowContext flowContext, FlowInfo flowInfo) {
32                 return flowInfo;
33         }
34
35         public FieldBinding fieldBinding() {
36                 // this method should be sent one FIELD-tagged references
37                 // (ref.bits & BindingIds.FIELD != 0)()
38                 return null;
39         }
40         // public void fieldStore(CodeStream codeStream, FieldBinding fieldBinding,
41         // MethodBinding syntheticWriteAccessor, boolean valueRequired) {
42         //
43         // if (fieldBinding.isStatic()) {
44         // if (valueRequired) {
45         // if ((fieldBinding.type == LongBinding) || (fieldBinding.type ==
46         // DoubleBinding)) {
47         // codeStream.dup2();
48         // } else {
49         // codeStream.dup();
50         // }
51         // }
52         // if (syntheticWriteAccessor == null) {
53         // codeStream.putstatic(fieldBinding);
54         // } else {
55         // codeStream.invokestatic(syntheticWriteAccessor);
56         // }
57         // } else { // Stack: [owner][new field value] ---> [new field
58         // value][owner][new field value]
59         // if (valueRequired) {
60         // if ((fieldBinding.type == LongBinding) || (fieldBinding.type ==
61         // DoubleBinding)) {
62         // codeStream.dup2_x1();
63         // } else {
64         // codeStream.dup_x1();
65         // }
66         // }
67         // if (syntheticWriteAccessor == null) {
68         // codeStream.putfield(fieldBinding);
69         // } else {
70         // codeStream.invokestatic(syntheticWriteAccessor);
71         // }
72         // }
73         // }
74         // public abstract void generateAssignment(BlockScope currentScope,
75         // CodeStream codeStream, Assignment assignment, boolean valueRequired);
76         //
77         // public abstract void generateCompoundAssignment(BlockScope currentScope,
78         // CodeStream codeStream, Expression expression, int operator, int
79         // assignmentImplicitConversion, boolean valueRequired);
80         //
81         // public abstract void generatePostIncrement(BlockScope currentScope,
82         // CodeStream codeStream, CompoundAssignment postIncrement, boolean
83         // valueRequired);
84
85 }