/*
* Copyright (C) 2010-2013 JPEXS
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
package com.jpexs.decompiler.flash.action;
import com.jpexs.decompiler.graph.GraphPart;
import com.jpexs.decompiler.graph.GraphSource;
import com.jpexs.decompiler.graph.GraphSourceItem;
import com.jpexs.decompiler.graph.GraphTargetItem;
import com.jpexs.helpers.Helper;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Stack;
import java.util.logging.Level;
import java.util.logging.Logger;
/**
*
* @author JPEXS
*/
public class ActionGraphSource extends GraphSource {
private List actions;
public int version;
private HashMap registerNames;
private HashMap variables;
private HashMap functions;
public List getActions() {
return actions;
}
public ActionGraphSource(List actions, int version, HashMap registerNames, HashMap variables, HashMap functions) {
this.actions = actions;
this.version = version;
this.registerNames = registerNames;
this.variables = variables;
this.functions = functions;
}
@Override
public int size() {
return actions.size();
}
@Override
public GraphSourceItem get(int pos) {
return actions.get(pos);
}
public void set(int pos, Action t) {
actions.set(pos, t);
}
@Override
public boolean isEmpty() {
return actions.isEmpty();
}
@Override
public List translatePart(GraphPart part, List