選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

AjClassFile.java 1.1KB

12345678910111213141516171819202122232425262728293031323334353637
  1. /*******************************************************************************
  2. * Copyright (c) 2004 IBM Corporation and others.
  3. * All rights reserved. This program and the accompanying materials
  4. * are made available under the terms of the Eclipse Public License v 2.0
  5. * which accompanies this distribution, and is available at
  6. * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt
  7. *
  8. * Contributors:
  9. * IBM Corporation - initial API and implementation
  10. *******************************************************************************/
  11. package org.aspectj.ajdt.internal.compiler;
  12. import org.aspectj.org.eclipse.jdt.internal.compiler.ClassFile;
  13. /**
  14. * @author colyer
  15. *
  16. * XXX lightweight subclass of ClassFile that only genuinely supports fileName and getBytes
  17. * operations. This nasty hack enables us to keep the rest of the implementation much simpler.
  18. */
  19. public class AjClassFile extends ClassFile {
  20. char[] filename;
  21. byte[] bytes;
  22. public AjClassFile(char[] fileName, byte[] byteCodes) {
  23. this.filename = fileName;
  24. bytes = byteCodes;
  25. }
  26. public char[] fileName() {
  27. return filename;
  28. }
  29. public byte[] getBytes() {
  30. return bytes;
  31. }
  32. }